home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1994 …ember: Reference Library / Dev.CD Dec 94.toast / Technical Documentation / Mac Tech Notes (DocViewer) / FL • Files / FL33 Standard File Custom < prev    next >
MacBinary  |  1994-10-19  |  69.1 KB  |  [ONLN/HLX2]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
10% dexvert MacBinary (archive/macBinary) fallback Supported
100% file MacBinary II, inited, Mon Oct 3 07:42:02 1994, modified Wed Oct 19 07:49:53 1994, creator 'HLX2', type 'ONLN', 67266 bytes "FL33 Standard File Custom" , at 0x10742 3294 bytes resource default (weak)
99% file DIY-Thermocam raw data (Lepton 3.x), scale 26144-29800, spot sensor temperature 0.000000, unit fahrenheit, color scheme 0, calibration: offset 0.000000, slope 54082624.000000 default (weak)
98% file data default
100% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[ONLN]
macFileCreator[HLX2]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 19 46 4c 33 33 20 53 | 74 61 6e 64 61 72 64 20 |..FL33 S|tandard |
|00000010| 46 69 6c 65 20 43 75 73 | 74 6f 6d 00 00 00 00 00 |File Cus|tom.....|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 4f 4e 4c 4e 48 4c 58 | 32 01 00 00 00 00 00 00 |.ONLNHLX|2.......|
|00000050| 00 00 00 00 01 06 c2 00 | 00 0c de aa b5 9e 8a aa |........|........|
|00000060| ca b8 61 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..a.....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 b9 b6 00 00 |........|........|
|00000080| 46 4c 20 33 33 20 2d 20 | 53 74 61 6e 64 61 72 64 |FL 33 - |Standard|
|00000090| 20 46 69 6c 65 20 43 75 | 73 74 6f 6d 69 7a 61 74 | File Cu|stomizat|
|000000a0| 69 6f 6e 0d 46 69 6c 65 | 73 09 09 0d 52 65 76 69 |ion.File|s...Revi|
|000000b0| 73 65 64 20 62 79 3a 09 | 09 4d 61 72 63 68 20 31 |sed by:.|.March 1|
|000000c0| 39 38 38 0d 57 72 69 74 | 74 65 6e 20 62 79 3a 09 |988.Writ|ten by:.|
|000000d0| 4a 69 6d 20 46 72 69 65 | 64 6c 61 6e 64 65 72 09 |Jim Frie|dlander.|
|000000e0| 4f 63 74 6f 62 65 72 20 | 31 39 38 35 0d 54 68 69 |October |1985.Thi|
|000000f0| 73 20 6e 6f 74 65 20 63 | 6f 6e 74 61 69 6e 73 20 |s note c|ontains |
|00000100| 61 6e 20 65 78 61 6d 70 | 6c 65 20 70 72 6f 67 72 |an examp|le progr|
|00000110| 61 6d 20 74 68 61 74 20 | 64 65 6d 6f 6e 73 74 72 |am that |demonstr|
|00000120| 61 74 65 73 20 68 6f 77 | 20 53 46 50 47 65 74 46 |ates how| SFPGetF|
|00000130| 69 6c 65 20 63 61 6e 20 | 62 65 20 63 75 73 74 6f |ile can |be custo|
|00000140| 6d 69 7a 65 64 20 75 73 | 69 6e 67 20 74 68 65 20 |mized us|ing the |
|00000150| 64 69 61 6c 6f 67 20 68 | 6f 6f 6b 20 61 6e 64 20 |dialog h|ook and |
|00000160| 66 69 6c 65 20 66 69 6c | 74 65 72 20 66 75 6e 63 |file fil|ter func|
|00000170| 74 69 6f 6e 73 2e 0d 53 | 46 50 47 65 74 46 69 6c |tions..S|FPGetFil|
|00000180| 65 d5 73 20 64 69 61 6c | 6f 67 20 68 6f 6f 6b 20 |e.s dial|og hook |
|00000190| 66 75 6e 63 74 69 6f 6e | 20 61 6e 64 20 66 69 6c |function| and fil|
|000001a0| 65 20 66 69 6c 74 65 72 | 20 66 75 6e 63 74 69 6f |e filter| functio|
|000001b0| 6e 20 65 6e 61 62 6c 65 | 20 79 6f 75 20 74 6f 20 |n enable| you to |
|000001c0| 63 75 73 74 6f 6d 69 7a | 65 20 53 46 50 47 65 74 |customiz|e SFPGet|
|000001d0| 46 69 6c 65 d5 73 20 62 | 65 68 61 76 69 6f 72 20 |File.s b|ehavior |
|000001e0| 74 6f 20 66 69 74 20 74 | 68 65 20 6e 65 65 64 73 |to fit t|he needs|
|000001f0| 20 6f 66 20 79 6f 75 72 | 20 61 70 70 6c 69 63 61 | of your| applica|
|00000200| 74 69 6f 6e 2e 20 54 68 | 69 73 20 74 65 63 68 6e |tion. Th|is techn|
|00000210| 69 63 61 6c 20 6e 6f 74 | 65 20 63 6f 6e 73 69 73 |ical not|e consis|
|00000220| 74 73 20 70 72 69 6d 61 | 72 69 6c 79 20 6f 66 20 |ts prima|rily of |
|00000230| 61 20 73 68 6f 72 74 20 | 65 78 61 6d 70 6c 65 20 |a short |example |
|00000240| 70 72 6f 67 72 61 6d 20 | 74 68 61 74 09 0d 09 09 |program |that....|
|00000250| 0d 31 29 20 63 68 61 6e | 67 65 73 20 74 68 65 20 |.1) chan|ges the |
|00000260| 74 69 74 6c 65 20 6f 66 | 20 74 68 65 20 4f 70 65 |title of| the Ope|
|00000270| 6e 20 62 75 74 74 6f 6e | 20 74 6f 20 d4 4d 79 4f |n button| to .MyO|
|00000280| 70 65 6e d5 2c 0d 32 29 | 20 61 64 64 73 20 74 77 |pen.,.2)| adds tw|
|00000290| 6f 20 72 61 64 69 6f 20 | 62 75 74 74 6f 6e 73 20 |o radio |buttons |
|000002a0| 73 6f 20 74 68 61 74 20 | 74 68 65 20 75 73 65 72 |so that |the user|
|000002b0| 20 63 61 6e 20 63 68 6f | 6f 73 65 20 74 6f 20 64 | can cho|ose to d|
|000002c0| 69 73 70 6c 61 79 20 65 | 69 74 68 65 72 20 74 65 |isplay e|ither te|
|000002d0| 78 74 20 66 69 6c 65 73 | 20 6f 72 20 74 65 78 74 |xt files| or text|
|000002e0| 20 66 69 6c 65 73 20 61 | 6e 64 20 61 70 70 6c 69 | files a|nd appli|
|000002f0| 63 61 74 69 6f 6e 73 2e | 0d 33 29 20 61 64 64 73 |cations.|.3) adds|
|00000300| 20 61 20 71 75 69 74 20 | 62 75 74 74 6f 6e 20 74 | a quit |button t|
|00000310| 6f 20 74 68 65 20 53 46 | 50 47 65 74 46 69 6c 65 |o the SF|PGetFile|
|00000320| 20 64 69 61 6c 6f 67 2c | 09 09 0d 41 6c 6c 20 74 | dialog,|...All t|
|00000330| 68 69 73 20 69 73 20 64 | 6f 6e 65 20 69 6e 20 61 |his is d|one in a|
|00000340| 20 77 61 79 20 73 6f 20 | 61 73 20 74 6f 20 70 72 | way so |as to pr|
|00000350| 6f 76 69 64 65 20 63 6f | 6d 70 61 74 69 62 69 6c |ovide co|mpatibil|
|00000360| 69 74 79 20 77 69 74 68 | 20 74 68 65 20 4d 61 63 |ity with| the Mac|
|00000370| 69 6e 74 6f 73 68 20 46 | 69 6c 65 20 53 79 73 74 |intosh F|ile Syst|
|00000380| 65 6d 20 28 4d 46 53 29 | 2c 20 74 68 65 20 48 69 |em (MFS)|, the Hi|
|00000390| 65 72 61 72 63 68 69 63 | 61 6c 20 46 69 6c 65 20 |erarchic|al File |
|000003a0| 53 79 73 74 65 6d 20 28 | 48 46 53 29 20 61 6e 64 |System (|HFS) and|
|000003b0| 20 28 68 6f 70 65 66 75 | 6c 6c 79 29 20 66 75 74 | (hopefu|lly) fut|
|000003c0| 75 72 65 20 73 79 73 74 | 65 6d 73 2e 20 49 66 20 |ure syst|ems. If |
|000003d0| 79 6f 75 20 68 61 76 65 | 20 61 6e 79 20 71 75 65 |you have| any que|
|000003e0| 73 74 69 6f 6e 73 20 61 | 73 20 79 6f 75 20 72 65 |stions a|s you re|
|000003f0| 61 64 2c 20 74 68 65 20 | 63 6f 6d 70 6c 65 74 65 |ad, the |complete|
|00000400| 20 73 6f 75 72 63 65 20 | 6f 66 20 74 68 65 20 64 | source |of the d|
|00000410| 65 6d 6f 20 70 72 6f 67 | 72 61 6d 20 61 6e 64 20 |emo prog|ram and |
|00000420| 74 68 65 20 72 65 73 6f | 75 72 63 65 20 63 6f 6d |the reso|urce com|
|00000430| 70 69 6c 65 72 20 69 6e | 70 75 74 20 66 69 6c 65 |piler in|put file|
|00000440| 20 69 73 20 70 72 6f 76 | 69 64 65 64 20 61 74 20 | is prov|ided at |
|00000450| 74 68 65 20 65 6e 64 20 | 6f 66 20 74 68 69 73 20 |the end |of this |
|00000460| 74 65 63 68 6e 69 63 61 | 6c 20 6e 6f 74 65 2e 0d |technica|l note..|
|00000470| 42 61 73 69 63 61 6c 6c | 79 2c 20 77 65 20 6e 65 |Basicall|y, we ne|
|00000480| 65 64 20 74 6f 20 64 6f | 20 74 68 72 65 65 20 74 |ed to do| three t|
|00000490| 68 69 6e 67 73 3a 20 61 | 64 64 20 6f 75 72 20 65 |hings: a|dd our e|
|000004a0| 78 74 72 61 20 63 6f 6e | 74 72 6f 6c 73 20 74 6f |xtra con|trols to|
|000004b0| 20 74 68 65 20 72 65 73 | 6f 75 72 63 65 20 63 6f | the res|ource co|
|000004c0| 6d 70 69 6c 65 72 20 69 | 6e 70 75 74 20 66 69 6c |mpiler i|nput fil|
|000004d0| 65 2c 20 77 72 69 74 65 | 20 61 20 64 69 61 6c 6f |e, write| a dialo|
|000004e0| 67 20 68 6f 6f 6b 20 66 | 75 6e 63 74 69 6f 6e 2c |g hook f|unction,|
|000004f0| 20 61 6e 64 20 77 72 69 | 74 65 20 61 20 66 69 6c | and wri|te a fil|
|00000500| 65 20 66 69 6c 74 65 72 | 20 66 75 6e 63 74 69 6f |e filter| functio|
|00000510| 6e 2e 0d 4d 6f 64 69 66 | 79 69 6e 67 20 74 68 65 |n..Modif|ying the|
|00000520| 20 52 65 73 6f 75 72 63 | 65 20 43 6f 6d 70 69 6c | Resourc|e Compil|
|00000530| 65 72 20 49 6e 70 75 74 | 20 46 69 6c 65 0d 46 69 |er Input| File.Fi|
|00000540| 72 73 74 20 77 65 20 6e | 65 65 64 20 74 6f 20 64 |rst we n|eed to d|
|00000550| 65 66 69 6e 65 20 61 20 | 64 69 61 6c 6f 67 20 69 |efine a |dialog i|
|00000560| 6e 20 6f 75 72 20 72 65 | 73 6f 75 72 63 65 20 66 |n our re|source f|
|00000570| 69 6c 65 2e 20 49 74 20 | 77 69 6c 6c 20 62 65 20 |ile. It |will be |
|00000580| 44 4c 4f 47 20 23 31 32 | 38 3a 0d 09 43 4f 4e 53 |DLOG #12|8:..CONS|
|00000590| 54 20 6d 79 44 4c 4f 47 | 49 44 20 3d 20 31 32 38 |T myDLOG|ID = 128|
|000005a0| 3b 0d 61 6e 64 20 69 74 | d5 73 20 52 65 7a 20 64 |;.and it|.s Rez d|
|000005b0| 65 73 63 72 69 70 74 69 | 6f 6e 20 69 73 3a 0d 09 |escripti|on is:..|
|000005c0| 72 65 73 6f 75 72 63 65 | 20 27 44 4c 4f 47 27 20 |resource| 'DLOG' |
|000005d0| 28 31 32 38 2c 20 70 75 | 72 67 65 61 62 6c 65 29 |(128, pu|rgeable)|
|000005e0| 20 7b 0d 09 20 20 20 20 | 7b 30 2c 20 30 2c 20 32 | {.. |{0, 0, 2|
|000005f0| 30 30 2c 20 33 34 39 7d | 2c 0d 09 20 20 20 20 64 |00, 349}|,.. d|
|00000600| 42 6f 78 50 72 6f 63 2c | 20 69 6e 76 69 73 69 62 |BoxProc,| invisib|
|00000610| 6c 65 2c 20 6e 6f 47 6f | 41 77 61 79 2c 0d 09 20 |le, noGo|Away,.. |
|00000620| 20 20 20 30 78 30 2c 0d | 09 20 20 20 20 31 32 38 | 0x0,.|. 128|
|00000630| 2c 0d 09 20 20 20 20 22 | 4d 79 47 46 22 0d 09 7d |,.. "|MyGF"..}|
|00000640| 3b 0d 54 68 65 20 61 62 | 6f 76 65 20 63 6f 6f 72 |;.The ab|ove coor|
|00000650| 64 69 6e 61 74 65 73 20 | 28 30 20 30 20 32 30 30 |dinates |(0 0 200|
|00000660| 20 33 34 39 29 20 61 72 | 65 20 66 72 6f 6d 20 74 | 349) ar|e from t|
|00000670| 68 65 20 73 74 61 6e 64 | 61 72 64 20 53 74 61 6e |he stand|ard Stan|
|00000680| 64 61 72 64 20 46 69 6c | 65 20 64 69 61 6c 6f 67 |dard Fil|e dialog|
|00000690| 2e 20 49 66 20 79 6f 75 | 20 6e 65 65 64 20 74 6f |. If you| need to|
|000006a0| 20 63 68 61 6e 67 65 20 | 74 68 65 20 73 69 7a 65 | change |the size|
|000006b0| 20 6f 66 20 74 68 65 20 | 64 69 61 6c 6f 67 20 74 | of the |dialog t|
|000006c0| 6f 20 61 63 63 6f 6d 6d | 6f 64 61 74 65 20 6e 65 |o accomm|odate ne|
|000006d0| 77 20 63 6f 6e 74 72 6f | 6c 73 2c 20 63 68 61 6e |w contro|ls, chan|
|000006e0| 67 65 20 74 68 65 73 65 | 20 63 6f 6f 72 64 69 6e |ge these| coordin|
|000006f0| 61 74 65 73 2e 20 4e 65 | 78 74 20 77 65 20 6e 65 |ates. Ne|xt we ne|
|00000700| 65 64 20 74 6f 20 61 64 | 64 20 61 20 44 49 54 4c |ed to ad|d a DITL|
|00000710| 20 69 6e 20 6f 75 72 20 | 72 65 73 6f 75 72 63 65 | in our |resource|
|00000720| 20 66 69 6c 65 20 74 68 | 61 74 20 69 73 20 74 68 | file th|at is th|
|00000730| 65 20 73 61 6d 65 20 61 | 73 20 74 68 65 20 73 74 |e same a|s the st|
|00000740| 61 6e 64 61 72 64 20 48 | 46 53 20 44 49 54 4c 20 |andard H|FS DITL |
|00000750| 23 d0 34 30 30 30 20 65 | 78 63 65 70 74 20 66 6f |#.4000 e|xcept fo|
|00000760| 72 20 6f 6e 65 20 69 74 | 65 6d 2e 20 57 65 20 6e |r one it|em. We n|
|00000770| 65 65 64 20 74 6f 20 63 | 68 61 6e 67 65 20 74 68 |eed to c|hange th|
|00000780| 65 20 6c 65 66 74 20 63 | 6f 6f 72 64 69 6e 61 74 |e left c|oordinat|
|00000790| 65 20 6f 66 20 55 73 65 | 72 49 74 65 6d 20 23 34 |e of Use|rItem #4|
|000007a0| 2c 20 6f 72 20 70 61 72 | 74 20 6f 66 20 74 68 65 |, or par|t of the|
|000007b0| 20 64 69 61 6c 6f 67 20 | 77 69 6c 6c 20 62 65 20 | dialog |will be |
|000007c0| 68 69 64 64 65 6e 20 69 | 66 20 77 65 d5 72 65 20 |hidden i|f we.re |
|000007d0| 72 75 6e 6e 69 6e 67 20 | 75 6e 64 65 72 20 4d 46 |running |under MF|
|000007e0| 53 3a 20 0d 09 2f 2a 20 | 5b 34 5d 20 2a 2f 0d 09 |S: ../* |[4] */..|
|000007f0| 2f 2a 20 6c 65 66 74 20 | 63 6f 6f 72 64 69 6e 61 |/* left |coordina|
|00000800| 74 65 20 63 68 61 6e 67 | 65 64 20 66 72 6f 6d 20 |te chang|ed from |
|00000810| 32 33 32 20 74 6f 20 32 | 35 32 20 73 6f 20 70 72 |232 to 2|52 so pr|
|00000820| 6f 67 72 61 6d 20 77 69 | 6c 6c 20 09 0d 09 20 20 |ogram wi|ll ... |
|00000830| 20 77 6f 72 6b 20 6f 6e | 20 4d 46 53 20 2a 2f 0d | work on| MFS */.|
|00000840| 09 7b 33 39 2c 20 32 35 | 32 2c 20 35 39 2c 20 33 |.{39, 25|2, 59, 3|
|00000850| 34 37 7d 2c 0d 09 55 73 | 65 72 49 74 65 6d 20 7b |47},..Us|erItem {|
|00000860| 0d 09 20 20 20 20 20 64 | 69 73 61 62 6c 65 64 0d |.. d|isabled.|
|00000870| 09 7d 3b 0d 4e 6f 6e 65 | 20 6f 66 20 74 68 65 20 |.};.None| of the |
|00000880| 6f 74 68 65 72 20 69 74 | 65 6d 73 20 6f 66 20 74 |other it|ems of t|
|00000890| 68 65 20 44 49 54 4c 20 | 73 68 6f 75 6c 64 20 62 |he DITL |should b|
|000008a0| 65 20 63 68 61 6e 67 65 | 64 2c 20 73 6f 20 74 68 |e change|d, so th|
|000008b0| 61 74 20 79 6f 75 72 20 | 70 72 6f 67 72 61 6d 20 |at your |program |
|000008c0| 77 69 6c 6c 20 72 65 6d | 61 69 6e 20 61 73 20 63 |will rem|ain as c|
|000008d0| 6f 6d 70 61 74 69 62 6c | 65 20 61 73 20 70 6f 73 |ompatibl|e as pos|
|000008e0| 73 69 62 6c 65 20 77 69 | 74 68 20 64 69 66 66 65 |sible wi|th diffe|
|000008f0| 72 65 6e 74 20 76 65 72 | 73 69 6f 6e 73 20 6f 66 |rent ver|sions of|
|00000900| 20 53 74 61 6e 64 61 72 | 64 20 46 69 6c 65 2e 20 | Standar|d File. |
|00000910| 46 69 6e 61 6c 6c 79 2c | 20 77 65 20 6e 65 65 64 |Finally,| we need|
|00000920| 20 74 6f 20 61 64 64 20 | 74 68 72 65 65 20 69 74 | to add |three it|
|00000930| 65 6d 73 20 74 6f 20 74 | 68 69 73 20 44 49 54 4c |ems to t|his DITL|
|00000940| 2c 20 74 77 6f 20 72 61 | 64 69 6f 20 62 75 74 74 |, two ra|dio butt|
|00000950| 6f 6e 73 20 61 6e 64 20 | 6f 6e 65 20 62 75 74 74 |ons and |one butt|
|00000960| 6f 6e 20 28 74 6f 20 73 | 65 72 76 65 20 61 73 20 |on (to s|erve as |
|00000970| 61 20 71 75 69 74 20 62 | 75 74 74 6f 6e 29 20 0d |a quit b|utton) .|
|00000980| 09 2f 2a 20 5b 31 31 5d | 20 74 65 78 74 42 75 74 |./* [11]| textBut|
|00000990| 74 6f 6e 20 2a 2f 0d 09 | 7b 31 2c 20 31 34 2c 20 |ton */..|{1, 14, |
|000009a0| 32 30 2c 20 31 34 32 7d | 2c 0d 09 52 61 64 69 6f |20, 142}|,..Radio|
|000009b0| 42 75 74 74 6f 6e 20 7b | 0d 09 20 20 20 20 65 6e |Button {|.. en|
|000009c0| 61 62 6c 65 64 2c 0d 09 | 20 20 20 20 22 54 65 78 |abled,..| "Tex|
|000009d0| 74 20 66 69 6c 65 73 20 | 6f 6e 6c 79 22 0d 09 7d |t files |only"..}|
|000009e0| 3b 0d 09 2f 2a 20 5b 31 | 32 5d 20 74 65 78 74 41 |;../* [1|2] textA|
|000009f0| 70 70 42 75 74 74 6f 6e | 20 2a 2f 0d 09 7b 31 39 |ppButton| */..{19|
|00000a00| 2c 20 31 34 2c 20 33 38 | 2c 20 31 37 36 7d 2c 0d |, 14, 38|, 176},.|
|00000a10| 09 52 61 64 69 6f 42 75 | 74 74 6f 6e 20 7b 0d 09 |.RadioBu|tton {..|
|00000a20| 20 20 20 20 65 6e 61 62 | 6c 65 64 2c 0d 09 20 20 | enab|led,.. |
|00000a30| 20 20 22 54 65 78 74 20 | 61 6e 64 20 61 70 70 6c | "Text |and appl|
|00000a40| 69 63 61 74 69 6f 6e 73 | 22 0d 09 7d 3b 0d 09 2f |ications|"..};../|
|00000a50| 2a 20 5b 31 33 5d 20 71 | 75 69 74 42 75 74 74 6f |* [13] q|uitButto|
|00000a60| 6e 20 2a 2f 0d 09 7b 36 | 2c 20 32 35 36 2c 20 32 |n */..{6|, 256, 2|
|00000a70| 34 2c 20 33 33 36 7d 2c | 0d 09 42 75 74 74 6f 6e |4, 336},|..Button|
|00000a80| 20 7b 0d 09 20 20 20 20 | 65 6e 61 62 6c 65 64 2c | {.. |enabled,|
|00000a90| 0d 09 20 20 20 20 22 51 | 75 69 74 22 0d 09 7d 0d |.. "Q|uit"..}.|
|00000aa0| 42 65 63 61 75 73 65 20 | 77 65 d5 76 65 20 61 64 |Because |we.ve ad|
|00000ab0| 64 65 64 20 74 68 72 65 | 65 20 69 74 65 6d 73 2c |ded thre|e items,|
|00000ac0| 20 77 65 20 6e 65 65 64 | 20 61 6c 73 6f 20 6e 65 | we need| also ne|
|00000ad0| 65 64 20 74 6f 20 63 68 | 61 6e 67 65 20 74 68 65 |ed to ch|ange the|
|00000ae0| 20 69 74 65 6d 20 63 6f | 75 6e 74 20 66 6f 72 20 | item co|unt for |
|00000af0| 74 68 65 20 44 49 54 4c | 20 66 72 6f 6d 20 31 30 |the DITL| from 10|
|00000b00| 20 74 6f 20 31 33 2e 20 | 57 65 20 61 6c 73 6f 20 | to 13. |We also |
|00000b10| 69 6e 63 6c 75 64 65 20 | 74 68 65 20 66 6f 6c 6c |include |the foll|
|00000b20| 6f 77 69 6e 67 20 69 6e | 20 6f 75 72 20 72 65 73 |owing in| our res|
|00000b30| 6f 75 72 63 65 20 66 69 | 6c 65 3a 0d 72 65 73 6f |ource fi|le:.reso|
|00000b40| 75 72 63 65 20 27 53 54 | 52 23 27 20 28 32 35 36 |urce 'ST|R#' (256|
|00000b50| 29 20 7b 0d 09 7b 2f 2a | 20 61 72 72 61 79 20 53 |) {..{/*| array S|
|00000b60| 74 72 69 6e 67 41 72 72 | 61 79 3a 20 31 20 65 6c |tringArr|ay: 1 el|
|00000b70| 65 6d 65 6e 74 73 20 2a | 2f 0d 09 20 20 20 20 2f |ements *|/.. /|
|00000b80| 2a 20 5b 31 5d 20 2a 2f | 0d 09 20 20 20 20 22 4d |* [1] */|.. "M|
|00000b90| 79 4f 70 65 6e 22 0d 09 | 7d 0d 7d 3b 0d 54 68 61 |yOpen"..|}.};.Tha|
|00000ba0| 74 d5 73 20 61 6c 6c 20 | 74 68 65 72 65 20 69 73 |t.s all |there is|
|00000bb0| 20 74 6f 20 6d 6f 64 69 | 66 79 20 69 6e 20 74 68 | to modi|fy in th|
|00000bc0| 65 20 72 65 73 6f 75 72 | 63 65 20 66 69 6c 65 2e |e resour|ce file.|
|00000bd0| 0d 54 68 65 20 44 69 61 | 6c 6f 67 20 48 6f 6f 6b |.The Dia|log Hook|
|00000be0| 0d 57 65 20 77 69 6c 6c | 20 62 65 20 63 61 6c 6c |.We will| be call|
|00000bf0| 69 6e 67 20 53 46 50 47 | 65 74 46 69 6c 65 20 61 |ing SFPG|etFile a|
|00000c00| 73 20 66 6f 6c 6c 6f 77 | 73 3a 0d 09 53 46 50 47 |s follow|s:..SFPG|
|00000c10| 65 74 46 69 6c 65 20 28 | 77 68 65 72 2c 20 27 27 |etFile (|wher, ''|
|00000c20| 2c 20 40 53 46 46 69 6c | 65 46 69 6c 74 65 72 2c |, @SFFil|eFilter,|
|00000c30| 20 4e 75 6d 46 69 6c 65 | 54 79 70 65 73 2c 09 09 | NumFile|Types,..|
|00000c40| 09 4d 79 46 69 6c 65 54 | 79 70 65 73 2c 20 40 4d |.MyFileT|ypes, @M|
|00000c50| 79 53 46 48 6f 6f 6b 2c | 20 72 65 70 6c 79 2c 20 |ySFHook,| reply, |
|00000c60| 6d 79 44 4c 4f 47 49 44 | 2c 6e 69 6c 29 3b 0d 4e |myDLOGID|,nil);.N|
|00000c70| 6f 74 69 63 65 20 74 68 | 61 74 20 77 65 d5 72 65 |otice th|at we.re|
|00000c80| 20 70 61 73 73 69 6e 67 | 20 40 4d 79 53 46 48 6f | passing| @MySFHo|
|00000c90| 6f 6b 20 74 6f 20 53 74 | 61 6e 64 61 72 64 20 46 |ok to St|andard F|
|00000ca0| 69 6c 65 2e 20 54 68 69 | 73 20 69 73 20 74 68 65 |ile. Thi|s is the|
|00000cb0| 20 61 64 64 72 65 73 73 | 20 6f 66 20 6f 75 72 20 | address| of our |
|00000cc0| 64 69 61 6c 6f 67 20 68 | 6f 6f 6b 20 72 6f 75 74 |dialog h|ook rout|
|00000cd0| 69 6e 65 2e 20 4f 75 72 | 20 64 69 61 6c 6f 67 20 |ine. Our| dialog |
|00000ce0| 68 6f 6f 6b 20 69 73 20 | 64 65 63 6c 61 72 65 64 |hook is |declared|
|00000cf0| 20 61 73 3a 0d 09 46 55 | 4e 43 54 49 4f 4e 20 4d | as:..FU|NCTION M|
|00000d00| 79 53 46 48 6f 6f 6b 28 | 4d 79 53 46 69 74 65 6d |ySFHook(|MySFitem|
|00000d10| 3a 20 49 4e 54 45 47 45 | 52 3b 20 74 68 65 44 69 |: INTEGE|R; theDi|
|00000d20| 61 6c 6f 67 3a 20 44 69 | 61 6c 6f 67 50 74 72 29 |alog: Di|alogPtr)|
|00000d30| 3a 49 4e 54 45 47 45 52 | 3b 0d 41 20 64 69 61 6c |:INTEGER|;.A dial|
|00000d40| 6f 67 20 68 6f 6f 6b 20 | 72 6f 75 74 69 6e 65 20 |og hook |routine |
|00000d50| 61 6c 6c 6f 77 73 20 75 | 73 20 74 6f 20 73 65 65 |allows u|s to see|
|00000d60| 20 65 76 65 72 79 20 69 | 74 65 6d 20 68 69 74 20 | every i|tem hit |
|00000d70| 62 65 66 6f 72 65 20 73 | 74 61 6e 64 61 72 64 20 |before s|tandard |
|00000d80| 66 69 6c 65 20 61 63 74 | 73 20 6f 6e 20 69 74 2e |file act|s on it.|
|00000d90| 20 54 68 69 73 20 61 6c | 6c 6f 77 73 20 75 73 20 | This al|lows us |
|00000da0| 74 6f 20 68 61 6e 64 6c | 65 20 63 6f 6e 74 72 6f |to handl|e contro|
|00000db0| 6c 73 20 74 68 61 74 20 | 61 72 65 6e d5 74 20 69 |ls that |aren.t i|
|00000dc0| 6e 20 74 68 65 20 73 74 | 61 6e 64 61 72 64 20 53 |n the st|andard S|
|00000dd0| 46 50 47 65 74 46 69 6c | 65 d5 73 20 44 49 54 4c |FPGetFil|e.s DITL|
|00000de0| 20 6f 72 20 74 6f 20 68 | 61 6e 64 6c 65 20 73 74 | or to h|andle st|
|00000df0| 61 6e 64 61 72 64 20 63 | 6f 6e 74 72 6f 6c 73 20 |andard c|ontrols |
|00000e00| 69 6e 20 6e 6f 6e 2d 73 | 74 61 6e 64 61 72 64 20 |in non-s|tandard |
|00000e10| 77 61 79 73 2e 20 54 68 | 65 20 64 69 61 6c 6f 67 |ways. Th|e dialog|
|00000e20| 20 68 6f 6f 6b 20 69 6e | 20 74 68 69 73 20 65 78 | hook in| this ex|
|00000e30| 61 6d 70 6c 65 20 63 6f | 6e 73 69 73 74 73 20 6f |ample co|nsists o|
|00000e40| 66 20 61 20 63 61 73 65 | 20 73 74 61 74 65 6d 65 |f a case| stateme|
|00000e50| 6e 74 20 77 69 74 68 20 | 4d 79 53 46 69 74 65 6d |nt with |MySFitem|
|00000e60| 20 61 73 20 74 68 65 20 | 63 61 73 65 20 73 65 6c | as the |case sel|
|00000e70| 65 63 74 6f 72 2e 20 42 | 65 66 6f 72 65 20 53 46 |ector. B|efore SF|
|00000e80| 50 47 65 74 46 69 6c 65 | 20 64 69 73 70 6c 61 79 |PGetFile| display|
|00000e90| 73 20 69 74 73 20 64 69 | 61 6c 6f 67 2c 20 69 74 |s its di|alog, it|
|00000ea0| 20 63 61 6c 6c 73 20 6f | 75 72 20 64 69 61 6c 6f | calls o|ur dialo|
|00000eb0| 67 20 68 6f 6f 6b 2c 20 | 70 61 73 73 69 6e 67 20 |g hook, |passing |
|00000ec0| 69 74 20 61 20 d0 31 20 | 61 73 20 4d 79 53 46 69 |it a .1 |as MySFi|
|00000ed0| 74 65 6d 2e 20 54 68 69 | 73 20 67 69 76 65 73 20 |tem. Thi|s gives |
|00000ee0| 75 73 20 61 20 63 68 61 | 6e 63 65 20 74 6f 20 69 |us a cha|nce to i|
|00000ef0| 6e 69 74 69 61 6c 69 7a | 65 20 6f 75 72 20 63 6f |nitializ|e our co|
|00000f00| 6e 74 72 6f 6c 73 2e 20 | 48 65 72 65 20 77 65 20 |ntrols. |Here we |
|00000f10| 77 69 6c 6c 20 73 65 74 | 20 74 68 65 20 74 65 78 |will set| the tex|
|00000f20| 74 41 70 70 42 75 74 74 | 6f 6e 20 74 6f 20 6f 66 |tAppButt|on to of|
|00000f30| 66 20 61 6e 64 20 74 68 | 65 20 74 65 78 74 42 75 |f and th|e textBu|
|00000f40| 74 74 6f 6e 20 74 6f 20 | 6f 6e 3a 0d 09 47 65 74 |tton to |on:..Get|
|00000f50| 44 49 74 65 6d 28 74 68 | 65 44 69 61 6c 6f 67 2c |DItem(th|eDialog,|
|00000f60| 74 65 78 74 41 70 70 42 | 75 74 74 6f 6e 2c 69 74 |textAppB|utton,it|
|00000f70| 65 6d 54 79 70 65 2c 69 | 74 65 6d 54 6f 43 68 61 |emType,i|temToCha|
|00000f80| 6e 67 65 2c 69 74 65 6d | 42 6f 78 29 3b 0d 20 09 |nge,item|Box);. .|
|00000f90| 53 65 74 43 74 6c 56 61 | 6c 75 65 28 63 6f 6e 74 |SetCtlVa|lue(cont|
|00000fa0| 72 6f 6c 48 61 6e 64 6c | 65 28 69 74 65 6d 54 6f |rolHandl|e(itemTo|
|00000fb0| 43 68 61 6e 67 65 29 2c | 62 74 6e 4f 66 66 29 3b |Change),|btnOff);|
|00000fc0| 0d 20 09 47 65 74 44 49 | 74 65 6d 28 74 68 65 44 |. .GetDI|tem(theD|
|00000fd0| 69 61 6c 6f 67 2c 74 65 | 78 74 42 75 74 74 6f 6e |ialog,te|xtButton|
|00000fe0| 2c 69 74 65 6d 54 79 70 | 65 2c 69 74 65 6d 54 6f |,itemTyp|e,itemTo|
|00000ff0| 43 68 61 6e 67 65 2c 69 | 74 65 6d 42 6f 78 29 3b |Change,i|temBox);|
|00001000| 0d 20 09 53 65 74 43 74 | 6c 56 61 6c 75 65 28 63 |. .SetCt|lValue(c|
|00001010| 6f 6e 74 72 6f 6c 48 61 | 6e 64 6c 65 28 69 74 65 |ontrolHa|ndle(ite|
|00001020| 6d 54 6f 43 68 61 6e 67 | 65 29 2c 62 74 6e 4f 6e |mToChang|e),btnOn|
|00001030| 29 3b 0d 61 6e 64 20 77 | 65 20 63 61 6e 20 61 6c |);.and w|e can al|
|00001040| 73 6f 20 63 68 61 6e 67 | 65 20 74 68 65 20 74 69 |so chang|e the ti|
|00001050| 74 6c 65 20 6f 66 20 61 | 6e 20 65 78 69 73 74 69 |tle of a|n existi|
|00001060| 6e 67 20 63 6f 6e 74 72 | 6f 6c 2e 20 48 65 72 65 |ng contr|ol. Here|
|00001070| d5 73 20 68 6f 77 20 77 | 65 20 6d 69 67 68 74 20 |.s how w|e might |
|00001080| 63 68 61 6e 67 65 20 74 | 68 65 20 74 69 74 6c 65 |change t|he title|
|00001090| 20 6f 66 20 74 68 65 20 | 4f 70 65 6e 20 62 75 74 | of the |Open but|
|000010a0| 74 6f 6e 20 75 73 69 6e | 67 20 61 20 73 74 72 69 |ton usin|g a stri|
|000010b0| 6e 67 20 74 68 61 74 20 | 77 65 20 67 65 74 20 66 |ng that |we get f|
|000010c0| 72 6f 6d 20 61 20 72 65 | 73 6f 75 72 63 65 20 66 |rom a re|source f|
|000010d0| 69 6c 65 3a 0d 09 47 65 | 74 49 6e 64 53 74 72 69 |ile:..Ge|tIndStri|
|000010e0| 6e 67 28 62 75 74 74 6f | 6e 54 69 74 6c 65 2c 32 |ng(butto|nTitle,2|
|000010f0| 35 36 2c 31 29 3b 0d 20 | 09 49 66 20 62 75 74 74 |56,1);. |.If butt|
|00001100| 6f 6e 54 69 74 6c 65 20 | 3c 3e 20 27 27 20 74 68 |onTitle |<> '' th|
|00001110| 65 6e 20 42 65 67 69 6e | 20 20 20 20 20 20 20 20 |en Begin| |
|00001120| 20 7b 20 69 66 20 77 65 | 20 72 65 61 6c 6c 79 20 | { if we| really |
|00001130| 67 6f 74 20 74 68 65 20 | 72 65 73 6f 75 72 63 65 |got the |resource|
|00001140| 7d 0d 20 20 20 20 20 20 | 20 20 20 47 65 74 44 49 |}. | GetDI|
|00001150| 74 65 6d 28 74 68 65 44 | 69 61 6c 6f 67 2c 67 65 |tem(theD|ialog,ge|
|00001160| 74 4f 70 65 6e 2c 69 74 | 65 6d 54 79 70 65 2c 69 |tOpen,it|emType,i|
|00001170| 74 65 6d 54 6f 43 68 61 | 6e 67 65 2c 69 74 65 6d |temToCha|nge,item|
|00001180| 42 6f 78 29 3b 20 0d 20 | 20 20 20 20 20 20 20 20 |Box); . | |
|00001190| 53 65 74 43 74 69 74 6c | 65 28 63 6f 6e 74 72 6f |SetCtitl|e(contro|
|000011a0| 6c 48 61 6e 64 6c 65 28 | 69 74 65 6d 54 6f 43 68 |lHandle(|itemToCh|
|000011b0| 61 6e 67 65 29 2c 62 75 | 74 74 6f 6e 54 69 74 6c |ange),bu|ttonTitl|
|000011c0| 65 29 3b 0d 09 45 6e 64 | 3b 20 7b 69 66 7d 20 20 |e);..End|; {if} |
|000011d0| 20 20 20 20 20 20 7b 69 | 66 20 77 65 20 64 69 64 | {i|f we did|
|000011e0| 6e 27 74 20 67 65 74 20 | 74 68 65 20 72 65 73 6f |n't get |the reso|
|000011f0| 75 72 63 65 2c 20 64 6f | 6e 27 74 20 63 68 61 6e |urce, do|n't chan|
|00001200| 67 65 20 74 68 65 20 74 | 69 74 6c 65 7d 20 20 20 |ge the t|itle} |
|00001210| 0d 55 70 6f 6e 20 63 6f | 6d 70 6c 65 74 69 6f 6e |.Upon co|mpletion|
|00001220| 20 6f 66 20 6f 75 72 20 | 72 6f 75 74 69 6e 65 20 | of our |routine |
|00001230| 74 68 61 74 20 68 61 6e | 64 6c 65 73 20 74 68 65 |that han|dles the|
|00001240| 20 d0 31 2c 20 77 65 20 | 72 65 74 75 72 6e 20 61 | .1, we |return a|
|00001250| 20 d0 31 20 74 6f 20 73 | 74 61 6e 64 61 72 64 20 | .1 to s|tandard |
|00001260| 66 69 6c 65 3a 20 20 20 | 20 0d 20 0d 20 20 20 09 |file: | . . .|
|00001270| 4d 79 53 46 48 6f 6f 6b | 3a 3d 20 4d 79 53 46 49 |MySFHook|:= MySFI|
|00001280| 74 65 6d 3b 20 20 20 20 | 20 20 20 20 20 20 20 20 |tem; | |
|00001290| 20 20 7b 70 61 73 73 20 | 62 61 63 6b 20 74 68 65 | {pass |back the|
|000012a0| 20 73 61 6d 65 20 69 74 | 65 6d 20 77 65 20 77 65 | same it|em we we|
|000012b0| 72 65 20 73 65 6e 74 7d | 0d 57 65 20 6e 6f 77 20 |re sent}|.We now |
|000012c0| 68 61 76 65 20 61 20 53 | 46 50 47 65 74 46 69 6c |have a S|FPGetFil|
|000012d0| 65 20 64 69 61 6c 6f 67 | 20 64 69 73 70 6c 61 79 |e dialog| display|
|000012e0| 65 64 20 74 68 61 74 20 | 68 61 73 20 61 20 71 75 |ed that |has a qu|
|000012f0| 69 74 20 62 75 74 74 6f | 6e 20 61 6e 64 20 74 77 |it butto|n and tw|
|00001300| 6f 20 72 61 64 69 6f 20 | 62 75 74 74 6f 6e 73 20 |o radio |buttons |
|00001310| 28 74 68 65 20 74 65 78 | 74 4f 6e 6c 79 20 62 75 |(the tex|tOnly bu|
|00001320| 74 74 6f 6e 20 69 73 20 | 6f 6e 2c 20 74 68 65 20 |tton is |on, the |
|00001330| 54 65 78 74 41 70 70 20 | 62 75 74 74 6f 6e 20 69 |TextApp |button i|
|00001340| 73 20 6f 66 66 29 2e 20 | 49 6e 20 61 64 64 69 74 |s off). |In addit|
|00001350| 69 6f 6e 2c 20 74 68 65 | 20 73 74 61 6e 64 61 72 |ion, the| standar|
|00001360| 64 20 4f 70 65 6e 20 62 | 75 74 74 6f 6e 20 68 61 |d Open b|utton ha|
|00001370| 73 20 62 65 65 6e 20 72 | 65 6e 61 6d 65 64 20 74 |s been r|enamed t|
|00001380| 6f 20 4d 79 4f 70 65 6e | 20 28 6f 72 20 77 68 61 |o MyOpen| (or wha|
|00001390| 74 65 76 65 72 20 53 54 | 52 20 69 73 20 74 68 65 |tever ST|R is the|
|000013a0| 20 66 69 72 73 74 20 73 | 74 72 69 6e 67 20 69 6e | first s|tring in|
|000013b0| 20 53 54 52 23 20 32 35 | 36 29 2e 20 54 68 69 73 | STR# 25|6). This|
|000013c0| 20 77 61 73 20 61 6c 6c | 20 64 6f 6e 65 20 62 65 | was all| done be|
|000013d0| 66 6f 72 65 20 53 46 50 | 47 65 74 46 69 6c 65 20 |fore SFP|GetFile |
|000013e0| 64 69 73 70 6c 61 79 65 | 64 20 74 68 65 20 64 69 |displaye|d the di|
|000013f0| 61 6c 6f 67 2e 20 4f 6e | 63 65 20 6f 75 72 20 68 |alog. On|ce our h|
|00001400| 6f 6f 6b 20 69 73 20 65 | 78 69 74 65 64 2c 20 53 |ook is e|xited, S|
|00001410| 46 50 47 65 74 46 69 6c | 65 20 64 69 73 70 6c 61 |FPGetFil|e displa|
|00001420| 79 73 20 74 68 65 20 64 | 69 61 6c 6f 67 20 61 6e |ys the d|ialog an|
|00001430| 64 20 63 61 6c 6c 73 20 | 4d 6f 64 61 6c 44 69 61 |d calls |ModalDia|
|00001440| 6c 6f 67 2e 0d 57 68 65 | 6e 20 74 68 65 20 75 73 |log..Whe|n the us|
|00001450| 65 72 20 63 6c 69 63 6b | 73 20 6f 6e 20 61 6e 20 |er click|s on an |
|00001460| 69 74 65 6d 20 69 6e 20 | 74 68 65 20 64 69 61 6c |item in |the dial|
|00001470| 6f 67 2c 20 6f 75 72 20 | 68 6f 6f 6b 20 69 73 20 |og, our |hook is |
|00001480| 63 61 6c 6c 65 64 20 61 | 67 61 69 6e 2e 20 57 65 |called a|gain. We|
|00001490| 20 63 61 6e 20 74 68 65 | 6e 20 74 61 6b 65 20 61 | can the|n take a|
|000014a0| 70 70 72 6f 70 72 69 61 | 74 65 20 61 63 74 69 6f |ppropria|te actio|
|000014b0| 6e 73 2c 20 73 75 63 68 | 20 61 73 20 68 69 67 68 |ns, such| as high|
|000014c0| 6c 69 67 68 74 69 6e 67 | 20 74 68 65 20 74 65 78 |lighting| the tex|
|000014d0| 74 42 75 74 74 6f 6e 20 | 61 6e 64 20 75 6e 2d 68 |tButton |and un-h|
|000014e0| 69 67 68 6c 69 67 68 74 | 69 6e 67 20 74 68 65 20 |ighlight|ing the |
|000014f0| 74 65 78 74 41 70 70 42 | 75 74 74 6f 6e 20 69 66 |textAppB|utton if|
|00001500| 20 74 68 65 20 75 73 65 | 72 20 63 6c 69 63 6b 73 | the use|r clicks|
|00001510| 20 6f 6e 20 74 68 65 20 | 74 65 78 74 42 75 74 74 | on the |textButt|
|00001520| 6f 6e 2e 20 41 74 20 74 | 68 69 73 20 74 69 6d 65 |on. At t|his time|
|00001530| 2c 20 77 65 20 63 61 6e | 20 61 6c 73 6f 20 75 70 |, we can| also up|
|00001540| 64 61 74 65 20 61 20 67 | 6c 6f 62 61 6c 20 76 61 |date a g|lobal va|
|00001550| 72 69 61 62 6c 65 20 28 | 74 65 78 74 4f 6e 6c 79 |riable (|textOnly|
|00001560| 29 20 74 68 61 74 20 77 | 65 20 77 69 6c 6c 20 75 |) that w|e will u|
|00001570| 73 65 20 69 6e 20 6f 75 | 72 20 66 69 6c 65 20 66 |se in ou|r file f|
|00001580| 69 6c 74 65 72 20 66 75 | 6e 63 74 69 6f 6e 20 74 |ilter fu|nction t|
|00001590| 6f 20 74 65 6c 6c 20 75 | 73 20 77 68 69 63 68 20 |o tell u|s which |
|000015a0| 66 69 6c 65 73 20 74 6f | 20 64 69 73 70 6c 61 79 |files to| display|
|000015b0| 2e 20 4e 6f 74 69 63 65 | 20 74 68 61 74 20 77 65 |. Notice| that we|
|000015c0| 20 63 61 6e 20 72 65 64 | 69 73 70 6c 61 79 20 74 | can red|isplay t|
|000015d0| 68 65 20 66 69 6c 65 20 | 6c 69 73 74 20 62 79 20 |he file |list by |
|000015e0| 72 65 74 75 72 6e 69 6e | 67 20 61 20 31 30 31 20 |returnin|g a 101 |
|000015f0| 61 73 20 74 68 65 20 72 | 65 73 75 6c 74 20 6f 66 |as the r|esult of|
|00001600| 20 4d 79 53 46 48 6f 6f | 6b 2e 20 28 53 74 61 6e | MySFHoo|k. (Stan|
|00001610| 64 61 72 64 20 46 69 6c | 65 20 66 6f 72 20 53 79 |dard Fil|e for Sy|
|00001620| 73 74 65 6d 73 20 6e 65 | 77 65 72 20 74 68 61 6e |stems ne|wer than|
|00001630| 20 34 2e 33 20 77 69 6c | 6c 20 61 6c 73 6f 20 72 | 4.3 wil|l also r|
|00001640| 65 61 64 20 74 68 65 20 | 6c 6f 77 20 6d 65 6d 6f |ead the |low memo|
|00001650| 72 79 20 67 6c 6f 62 61 | 6c 73 2c 20 43 75 72 44 |ry globa|ls, CurD|
|00001660| 69 72 53 74 6f 72 65 20 | 61 6e 64 20 53 46 53 61 |irStore |and SFSa|
|00001670| 76 65 44 69 73 6b 2c 20 | 61 6e 64 20 73 77 69 74 |veDisk, |and swit|
|00001680| 63 68 20 64 69 72 65 63 | 74 6f 72 69 65 73 20 77 |ch direc|tories w|
|00001690| 68 65 6e 20 6e 65 63 65 | 73 73 61 72 79 20 69 66 |hen nece|ssary if|
|000016a0| 20 61 20 31 30 31 20 69 | 73 20 72 65 74 75 72 6e | a 101 i|s return|
|000016b0| 65 64 20 61 73 20 74 68 | 65 20 72 65 73 75 6c 74 |ed as th|e result|
|000016c0| 2e 20 54 68 75 73 2c 20 | 79 6f 75 20 63 61 6e 20 |. Thus, |you can |
|000016d0| 70 6f 69 6e 74 20 53 74 | 61 6e 64 61 72 64 20 46 |point St|andard F|
|000016e0| 69 6c 65 20 74 6f 20 61 | 20 6e 65 77 20 64 69 72 |ile to a| new dir|
|000016f0| 65 63 74 6f 72 79 2c 20 | 6f 72 20 61 20 6e 65 77 |ectory, |or a new|
|00001700| 20 64 69 73 6b 2e 29 20 | 46 6f 72 20 65 78 61 6d | disk.) |For exam|
|00001710| 70 6c 65 2c 20 77 68 65 | 6e 20 74 68 65 20 74 65 |ple, whe|n the te|
|00001720| 78 74 42 75 74 74 6f 6e | 20 69 73 20 68 69 74 20 |xtButton| is hit |
|00001730| 77 65 20 74 75 72 6e 20 | 74 68 65 20 74 65 78 74 |we turn |the text|
|00001740| 41 70 70 42 75 74 74 6f | 6e 20 6f 66 66 2c 20 74 |AppButto|n off, t|
|00001750| 75 72 6e 20 74 68 65 20 | 74 65 78 74 42 75 74 74 |urn the |textButt|
|00001760| 6f 6e 20 6f 6e 2c 20 75 | 70 64 61 74 65 20 74 68 |on on, u|pdate th|
|00001770| 65 20 67 6c 6f 62 61 6c | 20 76 61 72 69 61 62 6c |e global| variabl|
|00001780| 65 20 74 65 78 74 4f 6e | 6c 79 2c 20 61 6e 64 20 |e textOn|ly, and |
|00001790| 74 65 6c 6c 20 53 46 50 | 47 65 74 46 69 6c 65 20 |tell SFP|GetFile |
|000017a0| 74 6f 20 72 65 64 69 73 | 70 6c 61 79 20 74 68 65 |to redis|play the|
|000017b0| 20 6c 69 73 74 20 6f 66 | 20 66 69 6c 65 73 20 74 | list of| files t|
|000017c0| 68 65 20 75 73 65 72 20 | 63 61 6e 20 63 68 6f 6f |he user |can choo|
|000017d0| 73 65 20 66 72 6f 6d 3a | 0d 09 69 66 20 6e 6f 74 |se from:|..if not|
|000017e0| 20 74 65 78 74 4f 6e 6c | 79 20 74 68 65 6e 20 42 | textOnl|y then B|
|000017f0| 65 67 69 6e 20 20 7b 69 | 66 20 74 65 78 74 4f 6e |egin {i|f textOn|
|00001800| 6c 79 20 77 61 73 20 74 | 75 72 6e 65 64 20 6f 66 |ly was t|urned of|
|00001810| 66 2c 20 74 75 72 6e 20 | 69 74 20 6f 6e 20 6e 6f |f, turn |it on no|
|00001820| 77 7d 0d 20 20 20 20 20 | 20 20 20 20 47 65 74 44 |w}. | GetD|
|00001830| 49 74 65 6d 28 74 68 65 | 44 69 61 6c 6f 67 2c 74 |Item(the|Dialog,t|
|00001840| 65 78 74 41 70 70 42 75 | 74 74 6f 6e 2c 69 74 65 |extAppBu|tton,ite|
|00001850| 6d 54 79 70 65 2c 69 74 | 65 6d 54 6f 43 68 61 6e |mType,it|emToChan|
|00001860| 67 65 2c 69 74 65 6d 42 | 6f 78 29 3b 0d 20 20 20 |ge,itemB|ox);. |
|00001870| 20 20 20 20 20 20 53 65 | 74 43 74 6c 56 61 6c 75 | Se|tCtlValu|
|00001880| 65 28 63 6f 6e 74 72 6f | 6c 48 61 6e 64 6c 65 28 |e(contro|lHandle(|
|00001890| 69 74 65 6d 54 6f 43 68 | 61 6e 67 65 29 2c 62 74 |itemToCh|ange),bt|
|000018a0| 6e 4f 66 66 29 3b 0d 20 | 20 20 20 20 20 20 20 20 |nOff);. | |
|000018b0| 47 65 74 44 49 74 65 6d | 28 74 68 65 44 69 61 6c |GetDItem|(theDial|
|000018c0| 6f 67 2c 74 65 78 74 42 | 75 74 74 6f 6e 2c 69 74 |og,textB|utton,it|
|000018d0| 65 6d 54 79 70 65 2c 69 | 74 65 6d 54 6f 43 68 61 |emType,i|temToCha|
|000018e0| 6e 67 65 2c 69 74 65 6d | 42 6f 78 29 3b 0d 20 20 |nge,item|Box);. |
|000018f0| 20 20 20 20 20 20 20 53 | 65 74 43 74 6c 56 61 6c | S|etCtlVal|
|00001900| 75 65 28 63 6f 6e 74 72 | 6f 6c 48 61 6e 64 6c 65 |ue(contr|olHandle|
|00001910| 28 69 74 65 6d 54 6f 43 | 68 61 6e 67 65 29 2c 62 |(itemToC|hange),b|
|00001920| 74 6e 4f 6e 29 3b 0d 20 | 20 20 20 20 20 20 20 20 |tnOn);. | |
|00001930| 74 65 78 74 4f 6e 6c 79 | 3a 3d 54 52 55 45 3b 20 |textOnly|:=TRUE; |
|00001940| 20 20 20 20 7b 74 6f 67 | 67 6c 65 20 6f 75 72 20 | {tog|gle our |
|00001950| 67 6c 6f 62 61 6c 20 76 | 61 72 69 61 62 6c 65 20 |global v|ariable |
|00001960| 66 6f 72 20 75 73 65 20 | 69 6e 20 74 68 65 20 66 |for use |in the f|
|00001970| 69 6c 74 65 72 7d 0d 20 | 20 20 20 20 20 20 20 20 |ilter}. | |
|00001980| 4d 79 53 46 48 6f 6f 6b | 3a 3d 20 72 65 44 72 61 |MySFHook|:= reDra|
|00001990| 77 4c 69 73 74 3b 7b 31 | 30 31 7d 20 20 20 20 20 |wList;{1|01} |
|000019a0| 20 20 7b 77 65 20 6d 75 | 73 74 20 74 65 6c 6c 20 | {we mu|st tell |
|000019b0| 53 46 20 74 6f 20 72 65 | 64 72 61 77 20 74 68 65 |SF to re|draw the|
|000019c0| 20 6c 69 73 74 7d 0d 20 | 09 45 6e 64 3b 20 20 7b | list}. |.End; {|
|000019d0| 69 66 20 6e 6f 74 20 74 | 65 78 74 4f 6e 6c 79 7d |if not t|extOnly}|
|000019e0| 0d 49 66 20 6f 75 72 20 | 71 75 69 74 20 62 75 74 |.If our |quit but|
|000019f0| 74 6f 6e 20 69 73 20 68 | 69 74 2c 20 77 65 20 63 |ton is h|it, we c|
|00001a00| 61 6e 20 70 61 73 73 20 | 53 46 50 47 65 74 46 69 |an pass |SFPGetFi|
|00001a10| 6c 65 20 62 61 63 6b 20 | 74 68 65 20 63 61 6e 63 |le back |the canc|
|00001a20| 65 6c 20 62 75 74 74 6f | 6e 3a 0d 20 0d 09 4d 79 |el butto|n:. ..My|
|00001a30| 53 46 48 6f 6f 6b 3a 3d | 20 67 65 74 43 61 6e 63 |SFHook:=| getCanc|
|00001a40| 65 6c 3b 0d 49 66 20 6f | 6e 65 20 6f 66 20 53 46 |el;.If o|ne of SF|
|00001a50| 50 47 65 74 46 69 6c 65 | d5 73 20 73 74 61 6e 64 |PGetFile|.s stand|
|00001a60| 61 72 64 20 69 74 65 6d | 73 20 69 73 20 68 69 74 |ard item|s is hit|
|00001a70| 2c 20 69 74 20 69 73 20 | 76 65 72 79 20 69 6d 70 |, it is |very imp|
|00001a80| 6f 72 74 61 6e 74 20 74 | 6f 20 70 61 73 73 20 74 |ortant t|o pass t|
|00001a90| 68 61 74 20 69 74 65 6d | 20 62 61 63 6b 20 74 6f |hat item| back to|
|00001aa0| 20 53 46 50 47 65 74 46 | 69 6c 65 3a 0d 09 4d 79 | SFPGetF|ile:..My|
|00001ab0| 53 46 48 6f 6f 6b 3a 3d | 20 4d 79 53 46 49 74 65 |SFHook:=| MySFIte|
|00001ac0| 6d 3b 20 7b 70 61 73 73 | 20 62 61 63 6b 20 74 68 |m; {pass| back th|
|00001ad0| 65 20 73 61 6d 65 20 69 | 74 65 6d 20 77 65 20 77 |e same i|tem we w|
|00001ae0| 65 72 65 20 73 65 6e 74 | 7d 0d 54 68 65 20 46 69 |ere sent|}.The Fi|
|00001af0| 6c 65 20 46 69 6c 74 65 | 72 0d 52 65 6d 65 6d 62 |le Filte|r.Rememb|
|00001b00| 65 72 2c 20 77 65 20 63 | 61 6c 6c 65 64 20 53 46 |er, we c|alled SF|
|00001b10| 50 47 65 74 46 69 6c 65 | 20 61 73 20 66 6f 6c 6c |PGetFile| as foll|
|00001b20| 6f 77 73 3a 0d 09 53 46 | 50 47 65 74 46 69 6c 65 |ows:..SF|PGetFile|
|00001b30| 20 28 77 68 65 72 2c 20 | 27 27 2c 20 40 53 46 46 | (wher, |'', @SFF|
|00001b40| 69 6c 65 46 69 6c 74 65 | 72 2c 20 4e 75 6d 46 69 |ileFilte|r, NumFi|
|00001b50| 6c 65 54 79 70 65 73 2c | 0d 20 09 20 20 20 20 20 |leTypes,|. . |
|00001b60| 20 20 20 20 20 20 20 4d | 79 46 69 6c 65 54 79 70 | M|yFileTyp|
|00001b70| 65 73 2c 20 40 4d 79 53 | 46 48 6f 6f 6b 2c 20 72 |es, @MyS|FHook, r|
|00001b80| 65 70 6c 79 2c 6d 79 44 | 4c 4f 47 49 44 2c 6e 69 |eply,myD|LOGID,ni|
|00001b90| 6c 29 3b 0d 4e 6f 74 69 | 63 65 20 74 68 61 74 20 |l);.Noti|ce that |
|00001ba0| 77 65 d5 72 65 20 70 61 | 73 73 69 6e 67 20 40 53 |we.re pa|ssing @S|
|00001bb0| 46 46 69 6c 65 46 69 6c | 74 65 72 20 74 6f 20 53 |FFileFil|ter to S|
|00001bc0| 46 50 47 65 74 46 69 6c | 65 2e 20 54 68 69 73 20 |FPGetFil|e. This |
|00001bd0| 69 73 20 74 68 65 20 61 | 64 64 72 65 73 73 20 6f |is the a|ddress o|
|00001be0| 66 20 6f 75 72 20 66 69 | 6c 65 20 66 69 6c 74 65 |f our fi|le filte|
|00001bf0| 72 20 72 6f 75 74 69 6e | 65 2e 20 41 20 66 69 6c |r routin|e. A fil|
|00001c00| 65 20 66 69 6c 74 65 72 | 20 69 73 20 64 65 63 6c |e filter| is decl|
|00001c10| 61 72 65 64 20 61 73 3a | 0d 09 46 55 4e 43 54 49 |ared as:|..FUNCTI|
|00001c20| 4f 4e 20 53 46 46 69 6c | 65 46 69 6c 74 65 72 20 |ON SFFil|eFilter |
|00001c30| 28 70 3a 20 50 61 72 6d | 42 6c 6b 50 74 72 29 3a |(p: Parm|BlkPtr):|
|00001c40| 20 42 4f 4f 4c 45 41 4e | 3b 0d 41 20 66 69 6c 65 | BOOLEAN|;.A file|
|00001c50| 20 66 69 6c 74 65 72 20 | 72 6f 75 74 69 6e 65 20 | filter |routine |
|00001c60| 61 6c 6c 6f 77 73 20 75 | 73 20 74 6f 20 63 6f 6e |allows u|s to con|
|00001c70| 74 72 6f 6c 20 77 68 69 | 63 68 20 66 69 6c 65 73 |trol whi|ch files|
|00001c80| 20 53 46 50 47 65 74 46 | 69 6c 65 20 77 69 6c 6c | SFPGetF|ile will|
|00001c90| 20 64 69 73 70 6c 61 79 | 20 66 6f 72 20 74 68 65 | display| for the|
|00001ca0| 20 75 73 65 72 2e 20 4f | 75 72 20 66 69 6c 65 20 | user. O|ur file |
|00001cb0| 66 69 6c 74 65 72 20 69 | 73 20 63 61 6c 6c 65 64 |filter i|s called|
|00001cc0| 20 66 6f 72 20 65 76 65 | 72 79 20 66 69 6c 65 20 | for eve|ry file |
|00001cd0| 28 6f 66 20 74 68 65 20 | 74 79 70 65 28 73 29 20 |(of the |type(s) |
|00001ce0| 73 70 65 63 69 66 69 65 | 64 20 69 6e 20 74 68 65 |specifie|d in the|
|00001cf0| 20 74 79 70 65 6c 69 73 | 74 29 20 6f 6e 20 61 6e | typelis|t) on an|
|00001d00| 20 4d 46 53 20 64 69 73 | 6b 2c 20 6f 72 20 66 6f | MFS dis|k, or fo|
|00001d10| 72 20 65 76 65 72 79 20 | 66 69 6c 65 20 28 6f 66 |r every |file (of|
|00001d20| 20 74 68 65 20 74 79 70 | 65 28 73 29 20 73 70 65 | the typ|e(s) spe|
|00001d30| 63 69 66 69 65 64 20 69 | 6e 20 74 68 65 20 74 79 |cified i|n the ty|
|00001d40| 70 65 6c 69 73 74 29 20 | 69 6e 20 74 68 65 20 63 |pelist) |in the c|
|00001d50| 75 72 72 65 6e 74 20 64 | 69 72 65 63 74 6f 72 79 |urrent d|irectory|
|00001d60| 20 6f 6e 20 61 6e 20 48 | 46 53 20 64 69 73 6b 2e | on an H|FS disk.|
|00001d70| 20 49 6e 20 61 64 64 69 | 74 69 6f 6e 2c 20 53 46 | In addi|tion, SF|
|00001d80| 50 47 65 74 46 69 6c 65 | 20 64 69 73 70 6c 61 79 |PGetFile| display|
|00001d90| 73 20 48 46 53 20 66 6f | 6c 64 65 72 73 20 66 6f |s HFS fo|lders fo|
|00001da0| 72 20 75 73 20 61 75 74 | 6f 6d 61 74 69 63 61 6c |r us aut|omatical|
|00001db0| 6c 79 2e 20 4f 75 72 20 | 66 69 6c 65 20 66 69 6c |ly. Our |file fil|
|00001dc0| 74 65 72 20 73 65 6c 65 | 63 74 73 20 77 68 69 63 |ter sele|cts whic|
|00001dd0| 68 20 66 69 6c 65 73 20 | 73 68 6f 75 6c 64 20 61 |h files |should a|
|00001de0| 70 70 65 61 72 20 69 6e | 20 74 68 65 20 64 69 61 |ppear in| the dia|
|00001df0| 6c 6f 67 20 62 79 20 72 | 65 74 75 72 6e 69 6e 67 |log by r|eturning|
|00001e00| 20 46 41 4c 53 45 20 66 | 6f 72 20 65 76 65 72 79 | FALSE f|or every|
|00001e10| 20 66 69 6c 65 20 74 68 | 61 74 20 73 68 6f 75 6c | file th|at shoul|
|00001e20| 64 20 62 65 20 73 68 6f | 77 6e 20 61 6e 64 20 54 |d be sho|wn and T|
|00001e30| 52 55 45 20 66 6f 72 20 | 65 76 65 72 79 20 66 69 |RUE for |every fi|
|00001e40| 6c 65 20 74 68 61 74 20 | 73 68 6f 75 6c 64 6e d5 |le that |shouldn.|
|00001e50| 74 2e 0d 46 6f 72 20 65 | 78 61 6d 70 6c 65 2c 20 |t..For e|xample, |
|00001e60| 75 73 69 6e 67 20 6f 75 | 72 20 67 6c 6f 62 61 6c |using ou|r global|
|00001e70| 20 76 61 72 69 61 62 6c | 65 20 74 65 78 74 4f 6e | variabl|e textOn|
|00001e80| 6c 79 20 28 77 68 69 63 | 68 20 77 65 20 73 65 74 |ly (whic|h we set|
|00001e90| 20 69 6e 20 6f 75 72 20 | 64 69 61 6c 6f 67 20 68 | in our |dialog h|
|00001ea0| 6f 6f 6b 2c 20 72 65 6d | 65 6d 62 65 72 3f 29 3a |ook, rem|ember?):|
|00001eb0| 0d 09 46 55 4e 43 54 49 | 4f 4e 20 53 46 46 69 6c |..FUNCTI|ON SFFil|
|00001ec0| 65 46 69 6c 74 65 72 28 | 70 3a 70 61 72 6d 42 6c |eFilter(|p:parmBl|
|00001ed0| 6b 50 74 72 29 3a 62 6f | 6f 6c 65 61 6e 3b 20 0d |kPtr):bo|olean; .|
|00001ee0| 09 42 65 67 69 6e 20 7b | 53 46 46 69 6c 65 46 69 |.Begin {|SFFileFi|
|00001ef0| 6c 74 65 72 7d 0d 20 20 | 09 20 20 53 46 46 69 6c |lter}. |. SFFil|
|00001f00| 65 46 69 6c 74 65 72 3a | 3d 20 54 52 55 45 3b 20 |eFilter:|= TRUE; |
|00001f10| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001f20| 20 20 20 20 20 20 20 7b | 44 6f 6e 27 74 20 73 68 | {|Don't sh|
|00001f30| 6f 77 20 69 74 20 2d 2d | 20 64 65 66 61 75 6c 74 |ow it --| default|
|00001f40| 7d 0d 20 20 09 20 20 69 | 66 20 74 65 78 74 4f 6e |}. . i|f textOn|
|00001f50| 6c 79 20 74 68 65 6e 0d | 20 20 20 20 20 20 20 20 |ly then.| |
|00001f60| 20 20 20 69 66 20 70 5e | 2e 69 6f 46 6c 46 6e 64 | if p^|.ioFlFnd|
|00001f70| 72 49 6e 66 6f 2e 66 64 | 54 79 70 65 20 3d 20 27 |rInfo.fd|Type = '|
|00001f80| 54 45 58 54 27 20 74 68 | 65 6e 0d 20 20 20 20 20 |TEXT' th|en. |
|00001f90| 20 20 20 20 20 20 20 20 | 20 20 53 46 46 69 6c 65 | | SFFile|
|00001fa0| 46 69 6c 74 65 72 3a 3d | 20 46 41 4c 53 45 20 20 |Filter:=| FALSE |
|00001fb0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001fc0| 20 20 20 20 7b 53 68 6f | 77 20 54 45 58 54 20 66 | {Sho|w TEXT f|
|00001fd0| 69 6c 65 73 20 6f 6e 6c | 79 7d 0d 20 20 20 20 20 |iles onl|y}. |
|00001fe0| 20 20 20 20 20 20 65 6c | 73 65 20 42 65 67 69 6e | el|se Begin|
|00001ff0| 0d 20 20 20 20 20 20 20 | 20 20 20 20 45 6e 64 20 |. | End |
|00002000| 20 7b 64 75 6d 6d 79 20 | 65 6c 73 65 7d 0d 20 20 | {dummy |else}. |
|00002010| 20 20 20 20 20 65 6c 73 | 65 0d 20 20 20 20 20 20 | els|e. |
|00002020| 20 20 20 20 20 69 66 20 | 28 70 5e 2e 69 6f 46 6c | if |(p^.ioFl|
|00002030| 46 6e 64 72 49 6e 66 6f | 2e 66 64 54 79 70 65 20 |FndrInfo|.fdType |
|00002040| 3d 20 27 54 45 58 54 27 | 29 20 6f 72 20 0d 20 20 |= 'TEXT'|) or . |
|00002050| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00002060| 20 20 28 70 5e 2e 69 6f | 46 6c 46 6e 64 72 49 6e | (p^.io|FlFndrIn|
|00002070| 66 6f 2e 66 64 54 79 70 | 65 20 3d 20 27 41 50 50 |fo.fdTyp|e = 'APP|
|00002080| 4c 27 29 20 74 68 65 6e | 20 0d 20 20 20 20 20 20 |L') then| . |
|00002090| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|000020a0| 20 20 20 53 46 46 69 6c | 65 46 69 6c 74 65 72 3a | SFFil|eFilter:|
|000020b0| 3d 20 46 41 4c 53 45 3b | 20 20 20 20 20 20 20 7b |= FALSE;| {|
|000020c0| 20 73 68 6f 77 20 54 45 | 58 54 20 6f 72 20 41 50 | show TE|XT or AP|
|000020d0| 50 4c 20 66 69 6c 65 73 | 7d 0d 09 45 6e 64 3b 20 |PL files|}..End; |
|000020e0| 20 7b 53 46 46 69 6c 65 | 46 69 6c 74 65 72 7d 0d | {SFFile|Filter}.|
|000020f0| 53 46 50 47 65 74 46 69 | 6c 65 20 63 61 6c 6c 73 |SFPGetFi|le calls|
|00002100| 20 74 68 65 20 66 69 6c | 65 20 66 69 6c 74 65 72 | the fil|e filter|
|00002110| 20 61 66 74 65 72 20 69 | 74 20 68 61 73 20 63 61 | after i|t has ca|
|00002120| 6c 6c 65 64 20 6f 75 72 | 20 64 69 61 6c 6f 67 20 |lled our| dialog |
|00002130| 68 6f 6f 6b 2e 20 50 6c | 65 61 73 65 20 72 65 6d |hook. Pl|ease rem|
|00002140| 65 6d 62 65 72 20 74 68 | 61 74 20 74 68 65 20 66 |ember th|at the f|
|00002150| 69 6c 74 65 72 20 69 73 | 20 70 61 73 73 65 64 20 |ilter is| passed |
|00002160| 65 76 65 72 79 20 66 69 | 6c 65 20 6f 66 20 74 68 |every fi|le of th|
|00002170| 65 20 74 79 70 65 73 20 | 73 70 65 63 69 66 69 65 |e types |specifie|
|00002180| 64 20 69 6e 20 74 68 65 | 20 74 79 70 65 6c 69 73 |d in the| typelis|
|00002190| 74 20 28 4d 79 46 69 6c | 65 54 79 70 65 73 29 2e |t (MyFil|eTypes).|
|000021a0| 20 49 66 20 79 6f 75 20 | 77 61 6e 74 20 79 6f 75 | If you |want you|
|000021b0| 72 20 61 70 70 6c 69 63 | 61 74 69 6f 6e 20 74 6f |r applic|ation to|
|000021c0| 20 62 65 20 61 62 6c 65 | 20 74 6f 20 63 68 6f 6f | be able| to choo|
|000021d0| 73 65 20 66 72 6f 6d 20 | 61 6c 6c 20 66 69 6c 65 |se from |all file|
|000021e0| 73 2c 20 70 61 73 73 20 | 53 46 50 47 65 74 46 69 |s, pass |SFPGetFi|
|000021f0| 6c 65 20 61 20 d0 31 20 | 61 73 20 6e 75 6d 54 79 |le a .1 |as numTy|
|00002200| 70 65 73 2e 20 46 6f 72 | 20 69 6e 66 6f 72 6d 61 |pes. For| informa|
|00002210| 74 69 6f 6e 20 61 62 6f | 75 74 20 70 61 72 61 6d |tion abo|ut param|
|00002220| 65 74 65 72 73 20 74 6f | 20 53 46 50 47 65 74 46 |eters to| SFPGetF|
|00002230| 69 6c 65 20 74 68 61 74 | 20 68 61 76 65 6e d5 74 |ile that| haven.t|
|00002240| 20 62 65 65 6e 20 64 69 | 73 63 75 73 73 65 64 20 | been di|scussed |
|00002250| 69 6e 20 74 68 69 73 20 | 74 65 63 68 6e 69 63 61 |in this |technica|
|00002260| 6c 20 6e 6f 74 65 2c 20 | 73 65 65 20 74 68 65 20 |l note, |see the |
|00002270| 53 74 61 6e 64 61 72 64 | 20 46 69 6c 65 20 50 61 |Standard| File Pa|
|00002280| 63 6b 61 67 65 20 63 68 | 61 70 74 65 72 20 6f 66 |ckage ch|apter of|
|00002290| 20 49 6e 73 69 64 65 20 | 4d 61 63 69 6e 74 6f 73 | Inside |Macintos|
|000022a0| 68 2e 0d 54 68 61 74 d5 | 73 20 61 6c 6c 20 74 68 |h..That.|s all th|
|000022b0| 65 72 65 20 69 73 20 74 | 6f 20 69 74 21 21 20 4e |ere is t|o it!! N|
|000022c0| 6f 77 20 74 68 61 74 20 | 79 6f 75 20 6b 6e 6f 77 |ow that |you know|
|000022d0| 20 68 6f 77 20 74 6f 20 | 6d 6f 64 69 66 79 20 53 | how to |modify S|
|000022e0| 46 50 47 65 74 46 69 6c | 65 20 74 6f 20 73 75 69 |FPGetFil|e to sui|
|000022f0| 74 20 79 6f 75 72 20 6e | 65 65 64 73 2c 20 70 6c |t your n|eeds, pl|
|00002300| 65 61 73 65 20 64 6f 6e | d5 74 20 72 75 73 68 20 |ease don|.t rush |
|00002310| 6f 66 66 20 61 6e 64 20 | 6c 6f 61 64 20 75 70 20 |off and |load up |
|00002320| 74 68 65 20 64 69 61 6c | 6f 67 20 77 69 6e 64 6f |the dial|og windo|
|00002330| 77 20 77 69 74 68 20 61 | 6c 6c 20 6b 69 6e 64 73 |w with a|ll kinds|
|00002340| 20 6f 66 20 63 6f 6e 74 | 72 6f 6c 73 20 61 6e 64 | of cont|rols and|
|00002350| 20 74 65 78 74 2e 20 50 | 6c 65 61 73 65 20 6d 61 | text. P|lease ma|
|00002360| 6b 65 20 73 75 72 65 20 | 74 68 61 74 20 79 6f 75 |ke sure |that you|
|00002370| 20 61 64 68 65 72 65 20 | 74 6f 20 4d 61 63 69 6e | adhere |to Macin|
|00002380| 74 6f 73 68 20 69 6e 74 | 65 72 66 61 63 65 20 73 |tosh int|erface s|
|00002390| 74 61 6e 64 61 72 64 73 | 2e 20 53 69 6d 69 6c 61 |tandards|. Simila|
|000023a0| 72 20 74 65 63 68 6e 69 | 71 75 65 73 20 63 61 6e |r techni|ques can|
|000023b0| 20 62 65 20 75 73 65 64 | 20 77 69 74 68 20 53 46 | be used| with SF|
|000023c0| 47 65 74 46 69 6c 65 2c | 20 53 46 50 75 74 46 69 |GetFile,| SFPutFi|
|000023d0| 6c 65 20 61 6e 64 20 53 | 46 50 50 75 74 46 69 6c |le and S|FPPutFil|
|000023e0| 65 2e 0d 54 68 65 20 63 | 6f 6d 70 6c 65 74 65 20 |e..The c|omplete |
|000023f0| 73 6f 75 72 63 65 20 6f | 66 20 74 68 65 20 64 65 |source o|f the de|
|00002400| 6d 6f 20 70 72 6f 67 72 | 61 6d 20 61 6e 64 20 6f |mo progr|am and o|
|00002410| 66 20 74 68 65 20 72 65 | 73 6f 75 72 63 65 20 63 |f the re|source c|
|00002420| 6f 6d 70 69 6c 65 72 20 | 69 6e 70 75 74 20 66 69 |ompiler |input fi|
|00002430| 6c 65 20 66 6f 6c 6c 6f | 77 73 3a 0d 4d 50 57 20 |le follo|ws:.MPW |
|00002440| 50 61 73 63 61 6c 20 53 | 6f 75 72 63 65 0d 7b 24 |Pascal S|ource.{$|
|00002450| 52 2d 7d 0d 7b 4a 69 6d | 20 46 72 69 65 64 6c 61 |R-}.{Jim| Friedla|
|00002460| 6e 64 65 72 20 20 20 20 | 4d 61 63 69 6e 74 6f 73 |nder |Macintos|
|00002470| 68 20 54 65 63 68 6e 69 | 63 61 6c 20 53 75 70 70 |h Techni|cal Supp|
|00002480| 6f 72 74 09 20 20 20 20 | 39 2f 33 30 2f 38 35 7d |ort. |9/30/85}|
|00002490| 0d 70 72 6f 67 72 61 6d | 20 53 46 47 65 74 44 65 |.program| SFGetDe|
|000024a0| 6d 6f 3b 0d 55 53 45 53 | 0d 20 20 20 20 20 4d 65 |mo;.USES|. Me|
|000024b0| 6d 54 79 70 65 73 2c 0d | 20 20 20 20 20 51 75 69 |mTypes,.| Qui|
|000024c0| 63 6b 44 72 61 77 2c 0d | 20 20 20 20 20 4f 53 49 |ckDraw,.| OSI|
|000024d0| 6e 74 66 2c 0d 20 20 20 | 20 20 54 6f 6f 6c 49 6e |ntf,. | ToolIn|
|000024e0| 74 66 2c 0d 20 20 20 20 | 20 50 61 63 6b 49 6e 74 |tf,. | PackInt|
|000024f0| 66 3b 0d 7b 24 44 2b 7d | 0d 43 4f 4e 53 54 0d 20 |f;.{$D+}|.CONST. |
|00002500| 20 6d 79 44 4c 4f 47 49 | 44 20 3d 20 31 32 38 3b | myDLOGI|D = 128;|
|00002510| 09 7b 49 44 20 6f 66 20 | 6f 75 72 20 64 69 61 6c |.{ID of |our dial|
|00002520| 6f 67 20 66 6f 72 20 75 | 73 65 20 77 69 74 68 20 |og for u|se with |
|00002530| 53 46 50 47 65 74 46 69 | 6c 65 7d 0d 56 41 52 0d |SFPGetFi|le}.VAR.|
|00002540| 20 20 77 68 65 72 3a 20 | 50 6f 69 6e 74 3b 09 09 | wher: |Point;..|
|00002550| 7b 20 77 68 65 72 65 20 | 74 6f 20 64 69 73 70 6c |{ where |to displ|
|00002560| 61 79 20 64 69 61 6c 6f | 67 20 7d 0d 20 20 72 65 |ay dialo|g }. re|
|00002570| 70 6c 79 3a 20 53 46 52 | 65 70 6c 79 3b 09 09 7b |ply: SFR|eply;..{|
|00002580| 20 72 65 70 6c 79 20 72 | 65 63 6f 72 64 20 7d 0d | reply r|ecord }.|
|00002590| 20 20 74 65 78 74 4f 6e | 6c 79 3a 20 42 4f 4f 4c | textOn|ly: BOOL|
|000025a0| 45 41 4e 3b 09 09 7b 20 | 74 65 6c 6c 73 20 75 73 |EAN;..{ |tells us|
|000025b0| 20 77 68 69 63 68 20 66 | 69 6c 65 73 20 61 72 65 | which f|iles are|
|000025c0| 20 63 75 72 72 65 6e 74 | 6c 79 20 62 65 69 6e 67 | current|ly being|
|000025d0| 20 64 69 73 70 6c 61 79 | 65 64 7d 0d 20 20 6d 79 | display|ed}. my|
|000025e0| 46 69 6c 65 54 79 70 65 | 73 3a 20 53 46 54 79 70 |FileType|s: SFTyp|
|000025f0| 65 4c 69 73 74 3b 20 20 | 20 20 20 20 7b 20 77 65 |eList; | { we|
|00002600| 20 77 6f 6e 27 74 20 61 | 63 74 75 61 6c 6c 79 20 | won't a|ctually |
|00002610| 75 73 65 20 74 68 69 73 | 20 7d 0d 20 20 4e 75 6d |use this| }. Num|
|00002620| 46 69 6c 65 54 79 70 65 | 73 3a 20 69 6e 74 65 67 |FileType|s: integ|
|00002630| 65 72 3b 0d 7b 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |er;.{---|--------|
|00002640| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002650| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002660| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002670| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002680| 2d 7d 0d 46 55 4e 43 54 | 49 4f 4e 20 4d 79 53 46 |-}.FUNCT|ION MySF|
|00002690| 48 6f 6f 6b 28 4d 79 53 | 46 69 74 65 6d 3a 69 6e |Hook(MyS|Fitem:in|
|000026a0| 74 65 67 65 72 3b 20 74 | 68 65 44 69 61 6c 6f 67 |teger; t|heDialog|
|000026b0| 3a 44 69 61 6c 6f 67 50 | 74 72 29 3a 20 69 6e 74 |:DialogP|tr): int|
|000026c0| 65 67 65 72 3b 0d 43 4f | 4e 53 54 0d 20 20 74 65 |eger;.CO|NST. te|
|000026d0| 78 74 42 75 74 74 6f 6e | 09 09 3d 20 31 31 3b 20 |xtButton|..= 11; |
|000026e0| 20 09 7b 44 49 54 4c 20 | 69 74 65 6d 20 6e 75 6d | .{DITL |item num|
|000026f0| 62 65 72 20 6f 66 20 74 | 65 78 74 42 75 74 74 6f |ber of t|extButto|
|00002700| 6e 7d 0d 20 20 74 65 78 | 74 41 70 70 42 75 74 74 |n}. tex|tAppButt|
|00002710| 6f 6e 09 3d 20 31 32 3b | 20 20 09 7b 44 49 54 4c |on.= 12;| .{DITL|
|00002720| 20 69 74 65 6d 20 6e 75 | 6d 62 65 72 20 6f 66 20 | item nu|mber of |
|00002730| 74 65 78 74 41 70 70 42 | 75 74 74 6f 6e 7d 0d 20 |textAppB|utton}. |
|00002740| 20 71 75 69 74 42 75 74 | 74 6f 6e 09 09 3d 20 31 | quitBut|ton..= 1|
|00002750| 33 3b 20 20 09 7b 44 49 | 54 4c 20 69 74 65 6d 20 |3; .{DI|TL item |
|00002760| 6e 75 6d 62 65 72 20 6f | 66 20 71 75 69 74 42 75 |number o|f quitBu|
|00002770| 74 74 6f 6e 7d 0d 20 20 | 73 74 61 79 49 6e 53 46 |tton}. |stayInSF|
|00002780| 09 20 09 3d 20 20 30 3b | 09 09 7b 69 66 20 77 65 |. .= 0;|..{if we|
|00002790| 20 77 61 6e 74 20 74 6f | 20 73 74 61 79 20 69 6e | want to| stay in|
|000027a0| 20 53 46 20 61 66 74 65 | 72 20 67 65 74 74 69 6e | SF afte|r gettin|
|000027b0| 67 20 61 6e 20 20 0d 09 | 09 09 09 09 20 4f 70 65 |g an ..|.... Ope|
|000027c0| 6e 20 68 69 74 2c 20 77 | 65 20 63 61 6e 20 70 61 |n hit, w|e can pa|
|000027d0| 73 73 20 62 61 63 6b 20 | 61 20 30 20 66 72 6f 6d |ss back |a 0 from|
|000027e0| 20 6f 75 72 20 20 09 09 | 20 20 09 09 09 20 20 09 | our ..| ... .|
|000027f0| 20 68 6f 6f 6b 20 28 6e | 6f 74 20 75 73 65 64 20 | hook (n|ot used |
|00002800| 69 6e 74 68 69 73 20 65 | 78 61 6d 70 6c 65 29 20 |inthis e|xample) |
|00002810| 7d 0d 20 20 66 69 72 73 | 74 54 69 6d 65 09 09 3d |}. firs|tTime..=|
|00002820| 20 2d 31 3b 09 09 7b 74 | 68 65 20 66 69 72 73 74 | -1;..{t|he first|
|00002830| 20 74 69 6d 65 20 6f 75 | 72 20 68 6f 6f 6b 20 69 | time ou|r hook i|
|00002840| 73 20 63 61 6c 6c 65 64 | 2c 20 69 74 20 69 73 20 |s called|, it is |
|00002850| 0d 09 09 09 09 09 70 61 | 73 73 65 64 20 61 20 2d |......pa|ssed a -|
|00002860| 31 7d 0d 09 09 20 09 09 | 09 0d 7b 54 68 65 20 66 |1}... ..|..{The f|
|00002870| 6f 6c 6c 6f 77 69 6e 67 | 20 6c 69 6e 65 20 69 73 |ollowing| line is|
|00002880| 20 74 68 65 20 6b 65 79 | 20 74 6f 20 74 68 65 20 | the key| to the |
|00002890| 77 68 6f 6c 65 20 72 6f | 75 74 69 6e 65 20 2d 2d |whole ro|utine --|
|000028a0| 20 74 68 65 20 6d 61 67 | 69 63 20 31 30 31 21 21 | the mag|ic 101!!|
|000028b0| 7d 0d 20 20 72 65 44 72 | 61 77 4c 69 73 74 09 20 |}. reDr|awList. |
|000028c0| 3d 20 31 30 31 3b 09 7b | 72 65 74 75 72 6e 69 6e |= 101;.{|returnin|
|000028d0| 67 20 31 30 31 20 61 73 | 20 69 74 65 6d 20 6e 75 |g 101 as| item nu|
|000028e0| 6d 62 65 72 20 77 69 6c | 6c 20 63 61 75 73 65 0d |mber wil|l cause.|
|000028f0| 20 09 09 09 09 09 74 68 | 65 20 66 69 6c 65 20 6c | .....th|e file l|
|00002900| 69 73 74 20 74 6f 20 62 | 65 20 72 65 63 61 6c 63 |ist to b|e recalc|
|00002910| 75 6c 61 74 65 64 7d 0d | 20 20 62 74 6e 4f 6e 09 |ulated}.| btnOn.|
|00002920| 09 3d 20 31 3b 09 09 7b | 63 6f 6e 74 72 6f 6c 20 |.= 1;..{|control |
|00002930| 76 61 6c 75 65 20 66 6f | 72 20 6f 6e 7d 0d 20 20 |value fo|r on}. |
|00002940| 62 74 6e 4f 66 66 09 20 | 09 3d 20 30 3b 09 09 7b |btnOff. |.= 0;..{|
|00002950| 63 6f 6e 74 72 6f 6c 20 | 76 61 6c 75 65 20 66 6f |control |value fo|
|00002960| 72 20 6f 66 66 7d 0d 56 | 41 52 0d 20 20 69 74 65 |r off}.V|AR. ite|
|00002970| 6d 54 6f 43 68 61 6e 67 | 65 3a 20 48 61 6e 64 6c |mToChang|e: Handl|
|00002980| 65 3b 09 20 20 20 20 20 | 20 20 7b 6e 65 65 64 65 |e;. | {neede|
|00002990| 64 20 66 6f 72 20 47 65 | 74 44 49 74 65 6d 20 61 |d for Ge|tDItem a|
|000029a0| 6e 64 20 53 65 74 43 74 | 6c 56 61 6c 75 65 7d 0d |nd SetCt|lValue}.|
|000029b0| 20 20 69 74 65 6d 42 6f | 78 3a 52 65 63 74 3b 09 | itemBo|x:Rect;.|
|000029c0| 09 09 7b 6e 65 65 64 65 | 64 20 66 6f 72 20 47 65 |..{neede|d for Ge|
|000029d0| 74 44 49 74 65 6d 7d 0d | 20 20 69 74 65 6d 54 79 |tDItem}.| itemTy|
|000029e0| 70 65 3a 69 6e 74 65 67 | 65 72 3b 09 20 20 20 20 |pe:integ|er;. |
|000029f0| 20 20 20 20 09 7b 6e 65 | 65 64 65 64 20 66 6f 72 | .{ne|eded for|
|00002a00| 20 47 65 74 44 49 74 65 | 6d 7d 0d 20 20 62 75 74 | GetDIte|m}. but|
|00002a10| 74 6f 6e 54 69 74 6c 65 | 3a 20 53 74 72 32 35 35 |tonTitle|: Str255|
|00002a20| 3b 09 20 20 20 20 20 20 | 20 7b 6e 65 65 64 65 64 |;. | {needed|
|00002a30| 20 66 6f 72 20 47 65 74 | 49 6e 64 53 74 72 69 6e | for Get|IndStrin|
|00002a40| 67 7d 0d 42 65 67 69 6e | 20 7b 4d 79 53 46 48 6f |g}.Begin| {MySFHo|
|00002a50| 6f 6b 7d 0d 20 20 63 61 | 73 65 20 4d 79 53 46 49 |ok}. ca|se MySFI|
|00002a60| 74 65 6d 20 6f 66 0d 20 | 20 20 20 66 69 72 73 74 |tem of. | first|
|00002a70| 54 69 6d 65 3a 20 42 65 | 67 69 6e 09 20 20 20 20 |Time: Be|gin. |
|00002a80| 20 20 09 09 7b 20 62 65 | 66 6f 72 65 20 74 68 65 | ..{ be|fore the|
|00002a90| 20 64 69 61 6c 6f 67 20 | 69 73 20 64 72 61 77 6e | dialog |is drawn|
|00002aa0| 2c 20 6f 75 72 20 68 6f | 6f 6b 20 67 65 74 73 0d |, our ho|ok gets.|
|00002ab0| 20 09 09 09 09 09 63 61 | 6c 6c 65 64 20 77 69 74 | .....ca|lled wit|
|00002ac0| 68 20 61 20 2d 31 20 28 | 66 69 72 73 74 54 69 6d |h a -1 (|firstTim|
|00002ad0| 65 29 20 61 73 20 74 68 | 65 20 69 74 65 6d 20 73 |e) as th|e item s|
|00002ae0| 6f 0d 09 09 09 09 09 77 | 65 20 63 61 6e 20 63 68 |o......w|e can ch|
|00002af0| 61 6e 67 65 20 74 68 69 | 6e 67 73 20 6c 69 6b 65 |ange thi|ngs like|
|00002b00| 20 62 75 74 74 6f 6e 20 | 74 69 74 6c 65 73 2c 20 | button |titles, |
|00002b10| 0d 09 09 09 09 09 65 74 | 63 2e 20 7d 0d 7b 48 65 |......et|c. }.{He|
|00002b20| 72 65 20 77 65 20 77 69 | 6c 6c 20 73 65 74 20 74 |re we wi|ll set t|
|00002b30| 68 65 20 74 65 78 74 41 | 70 70 42 75 74 74 6f 6e |he textA|ppButton|
|00002b40| 20 74 6f 20 4f 46 46 2c | 20 74 68 65 20 74 65 78 | to OFF,| the tex|
|00002b50| 74 42 75 74 74 6f 6e 20 | 74 6f 20 4f 4e 7d 0d 20 |tButton |to ON}. |
|00002b60| 20 20 20 20 20 20 20 47 | 65 74 44 49 74 65 6d 28 | G|etDItem(|
|00002b70| 74 68 65 44 69 61 6c 6f | 67 2c 74 65 78 74 41 70 |theDialo|g,textAp|
|00002b80| 70 42 75 74 74 6f 6e 2c | 69 74 65 6d 54 79 70 65 |pButton,|itemType|
|00002b90| 2c 69 74 65 6d 54 6f 43 | 68 61 6e 67 65 2c 69 74 |,itemToC|hange,it|
|00002ba0| 65 6d 42 6f 78 29 3b 0d | 20 20 20 20 20 20 20 20 |emBox);.| |
|00002bb0| 53 65 74 43 74 6c 56 61 | 6c 75 65 28 63 6f 6e 74 |SetCtlVa|lue(cont|
|00002bc0| 72 6f 6c 48 61 6e 64 6c | 65 28 69 74 65 6d 54 6f |rolHandl|e(itemTo|
|00002bd0| 43 68 61 6e 67 65 29 2c | 62 74 6e 4f 66 66 29 3b |Change),|btnOff);|
|00002be0| 0d 20 20 20 20 20 20 20 | 20 47 65 74 44 49 74 65 |. | GetDIte|
|00002bf0| 6d 28 74 68 65 44 69 61 | 6c 6f 67 2c 74 65 78 74 |m(theDia|log,text|
|00002c00| 42 75 74 74 6f 6e 2c 69 | 74 65 6d 54 79 70 65 2c |Button,i|temType,|
|00002c10| 69 74 65 6d 54 6f 43 68 | 61 6e 67 65 2c 69 74 65 |itemToCh|ange,ite|
|00002c20| 6d 42 6f 78 29 3b 0d 20 | 20 20 20 20 20 20 20 53 |mBox);. | S|
|00002c30| 65 74 43 74 6c 56 61 6c | 75 65 28 63 6f 6e 74 72 |etCtlVal|ue(contr|
|00002c40| 6f 6c 48 61 6e 64 6c 65 | 28 69 74 65 6d 54 6f 43 |olHandle|(itemToC|
|00002c50| 68 61 6e 67 65 29 2c 62 | 74 6e 4f 6e 29 3b 0d 20 |hange),b|tnOn);. |
|00002c60| 20 20 20 20 20 20 20 47 | 65 74 49 6e 64 53 74 72 | G|etIndStr|
|00002c70| 69 6e 67 28 62 75 74 74 | 6f 6e 54 69 74 6c 65 2c |ing(butt|onTitle,|
|00002c80| 32 35 36 2c 31 29 3b 09 | 09 7b 67 65 74 20 74 68 |256,1);.|.{get th|
|00002c90| 65 20 62 75 74 74 6f 6e | 20 74 69 74 6c 65 20 66 |e button| title f|
|00002ca0| 72 6f 6d 20 61 20 09 09 | 09 09 09 09 09 20 72 65 |rom a ..|..... re|
|00002cb0| 73 6f 75 72 63 65 20 66 | 69 6c 65 7d 0d 20 20 20 |source f|ile}. |
|00002cc0| 20 20 20 20 20 49 66 20 | 62 75 74 74 6f 6e 54 69 | If |buttonTi|
|00002cd0| 74 6c 65 20 3c 3e 20 27 | 27 20 74 68 65 6e 20 42 |tle <> '|' then B|
|00002ce0| 65 67 69 6e 09 09 7b 20 | 69 66 20 77 65 20 67 6f |egin..{ |if we go|
|00002cf0| 74 20 74 68 65 20 72 65 | 73 6f 75 72 63 65 7d 0d |t the re|source}.|
|00002d00| 20 20 20 20 20 20 20 20 | 20 20 20 20 47 65 74 44 | | GetD|
|00002d10| 49 74 65 6d 28 74 68 65 | 44 69 61 6c 6f 67 2c 67 |Item(the|Dialog,g|
|00002d20| 65 74 4f 70 65 6e 2c 69 | 74 65 6d 54 79 70 65 2c |etOpen,i|temType,|
|00002d30| 69 74 65 6d 54 6f 43 68 | 61 6e 67 65 2c 69 74 65 |itemToCh|ange,ite|
|00002d40| 6d 42 6f 78 29 3b 20 0d | 09 09 09 09 09 09 09 7b |mBox); .|.......{|
|00002d50| 67 65 74 20 68 61 6e 64 | 6c 65 20 74 6f 20 6f 70 |get hand|le to op|
|00002d60| 65 6e 20 62 75 74 74 6f | 6e 7d 0d 20 20 20 20 20 |en butto|n}. |
|00002d70| 20 20 20 20 20 20 20 53 | 65 74 43 74 69 74 6c 65 | S|etCtitle|
|00002d80| 28 63 6f 6e 74 72 6f 6c | 48 61 6e 64 6c 65 28 69 |(control|Handle(i|
|00002d90| 74 65 6d 54 6f 43 68 61 | 6e 67 65 29 2c 62 75 74 |temToCha|nge),but|
|00002da0| 74 6f 6e 54 69 74 6c 65 | 29 3b 0d 20 20 20 20 20 |tonTitle|);. |
|00002db0| 20 20 20 45 6e 64 3b 20 | 7b 69 66 7d 09 09 09 09 | End; |{if}....|
|00002dc0| 7b 69 66 20 77 65 20 63 | 61 6e 27 74 20 67 65 74 |{if we c|an't get|
|00002dd0| 20 74 68 65 20 72 65 73 | 6f 75 72 63 65 2c 20 77 | the res|ource, w|
|00002de0| 65 0d 09 09 09 09 09 09 | 6a 75 73 74 20 77 6f 6e |e.......|just won|
|00002df0| 27 74 20 63 68 61 6e 67 | 65 20 74 68 65 20 6f 70 |'t chang|e the op|
|00002e00| 65 6e 20 62 75 74 74 6f | 6e 27 73 0d 09 09 09 09 |en butto|n's.....|
|00002e10| 09 09 74 69 74 6c 65 7d | 0d 20 20 20 20 20 20 20 |..title}|. |
|00002e20| 20 4d 79 53 46 48 6f 6f | 6b 3a 3d 20 4d 79 53 46 | MySFHoo|k:= MySF|
|00002e30| 49 74 65 6d 3b 09 09 7b | 70 61 73 73 20 62 61 63 |Item;..{|pass bac|
|00002e40| 6b 20 74 68 65 20 73 61 | 6d 65 20 69 74 65 6d 20 |k the sa|me item |
|00002e50| 77 65 20 77 65 72 65 0d | 09 09 09 09 09 09 20 73 |we were.|...... s|
|00002e60| 65 6e 74 7d 0d 20 20 20 | 20 45 6e 64 3b 20 20 7b |ent}. | End; {|
|00002e70| 66 69 72 73 74 54 69 6d | 65 7d 0d 7b 48 65 72 65 |firstTim|e}.{Here|
|00002e80| 20 77 65 20 77 69 6c 6c | 20 74 75 72 6e 20 74 68 | we will| turn th|
|00002e90| 65 20 74 65 78 74 41 70 | 70 42 75 74 74 6f 6e 20 |e textAp|pButton |
|00002ea0| 4f 46 46 2c 20 74 68 65 | 20 74 65 78 74 42 75 74 |OFF, the| textBut|
|00002eb0| 74 6f 6e 20 4f 4e 20 61 | 6e 64 20 72 65 64 72 61 |ton ON a|nd redra|
|00002ec0| 77 20 74 68 65 20 6c 69 | 73 74 7d 0d 20 20 20 20 |w the li|st}. |
|00002ed0| 74 65 78 74 42 75 74 74 | 6f 6e 3a 20 42 65 67 69 |textButt|on: Begi|
|00002ee0| 6e 0d 20 20 20 20 20 20 | 20 20 69 66 20 6e 6f 74 |n. | if not|
|00002ef0| 20 74 65 78 74 4f 6e 6c | 79 20 74 68 65 6e 20 42 | textOnl|y then B|
|00002f00| 65 67 69 6e 0d 20 20 20 | 20 20 20 20 20 20 20 20 |egin. | |
|00002f10| 20 47 65 74 44 49 74 65 | 6d 28 74 68 65 44 69 61 | GetDIte|m(theDia|
|00002f20| 6c 6f 67 2c 74 65 78 74 | 41 70 70 42 75 74 74 6f |log,text|AppButto|
|00002f30| 6e 2c 69 74 65 6d 54 79 | 70 65 2c 69 74 65 6d 54 |n,itemTy|pe,itemT|
|00002f40| 6f 43 68 61 6e 67 65 2c | 69 74 65 6d 42 6f 78 29 |oChange,|itemBox)|
|00002f50| 3b 0d 20 20 20 20 20 20 | 20 20 20 20 20 20 53 65 |;. | Se|
|00002f60| 74 43 74 6c 56 61 6c 75 | 65 28 63 6f 6e 74 72 6f |tCtlValu|e(contro|
|00002f70| 6c 48 61 6e 64 6c 65 28 | 69 74 65 6d 54 6f 43 68 |lHandle(|itemToCh|
|00002f80| 61 6e 67 65 29 2c 62 74 | 6e 4f 66 66 29 3b 0d 20 |ange),bt|nOff);. |
|00002f90| 20 20 20 20 20 20 20 20 | 20 20 20 47 65 74 44 49 | | GetDI|
|00002fa0| 74 65 6d 28 74 68 65 44 | 69 61 6c 6f 67 2c 74 65 |tem(theD|ialog,te|
|00002fb0| 78 74 42 75 74 74 6f 6e | 2c 69 74 65 6d 54 79 70 |xtButton|,itemTyp|
|00002fc0| 65 2c 69 74 65 6d 54 6f | 43 68 61 6e 67 65 2c 69 |e,itemTo|Change,i|
|00002fd0| 74 65 6d 42 6f 78 29 3b | 0d 20 20 20 20 20 20 20 |temBox);|. |
|00002fe0| 20 20 20 20 20 53 65 74 | 43 74 6c 56 61 6c 75 65 | Set|CtlValue|
|00002ff0| 28 63 6f 6e 74 72 6f 6c | 48 61 6e 64 6c 65 28 69 |(control|Handle(i|
|00003000| 74 65 6d 54 6f 43 68 61 | 6e 67 65 29 2c 62 74 6e |temToCha|nge),btn|
|00003010| 4f 6e 29 3b 0d 20 20 20 | 20 20 20 20 20 20 20 20 |On);. | |
|00003020| 20 74 65 78 74 4f 6e 6c | 79 3a 3d 54 52 55 45 3b | textOnl|y:=TRUE;|
|00003030| 0d 20 20 20 20 20 20 20 | 20 20 20 20 20 4d 79 53 |. | MyS|
|00003040| 46 48 6f 6f 6b 3a 3d 20 | 72 65 44 72 61 77 4c 69 |FHook:= |reDrawLi|
|00003050| 73 74 3b 09 7b 77 65 20 | 6d 75 73 74 20 74 65 6c |st;.{we |must tel|
|00003060| 6c 20 53 46 20 74 6f 20 | 72 65 64 72 61 77 20 74 |l SF to |redraw t|
|00003070| 68 65 20 6c 69 73 74 7d | 0d 20 20 20 20 20 20 20 |he list}|. |
|00003080| 20 45 6e 64 3b 20 20 7b | 69 66 20 6e 6f 74 20 74 | End; {|if not t|
|00003090| 65 78 74 4f 6e 6c 79 7d | 0d 20 20 20 20 45 6e 64 |extOnly}|. End|
|000030a0| 3b 20 20 7b 74 65 78 74 | 4f 6e 6c 79 42 75 74 74 |; {text|OnlyButt|
|000030b0| 6f 6e 7d 0d 7b 48 65 72 | 65 20 77 65 20 74 75 72 |on}.{Her|e we tur|
|000030c0| 6e 20 74 68 65 20 74 65 | 78 74 42 75 74 74 6f 6e |n the te|xtButton|
|000030d0| 20 4f 46 46 2c 20 74 68 | 65 20 74 65 78 74 41 70 | OFF, th|e textAp|
|000030e0| 70 42 75 74 74 6f 6e 20 | 4f 4e 20 61 6e 64 20 72 |pButton |ON and r|
|000030f0| 65 64 72 61 77 20 74 68 | 65 20 6c 69 73 74 7d 0d |edraw th|e list}.|
|00003100| 20 20 20 20 74 65 78 74 | 41 70 70 42 75 74 74 6f | text|AppButto|
|00003110| 6e 3a 20 42 65 67 69 6e | 0d 20 20 20 20 20 20 20 |n: Begin|. |
|00003120| 20 69 66 20 74 65 78 74 | 4f 6e 6c 79 20 74 68 65 | if text|Only the|
|00003130| 6e 20 42 65 67 69 6e 0d | 20 20 20 20 20 20 20 20 |n Begin.| |
|00003140| 20 20 20 20 47 65 74 44 | 49 74 65 6d 28 74 68 65 | GetD|Item(the|
|00003150| 44 69 61 6c 6f 67 2c 54 | 65 78 74 42 75 74 74 6f |Dialog,T|extButto|
|00003160| 6e 2c 69 74 65 6d 54 79 | 70 65 2c 69 74 65 6d 54 |n,itemTy|pe,itemT|
|00003170| 6f 43 68 61 6e 67 65 2c | 69 74 65 6d 42 6f 78 29 |oChange,|itemBox)|
|00003180| 3b 0d 20 20 20 20 20 20 | 20 20 20 20 20 20 53 65 |;. | Se|
|00003190| 74 43 74 6c 56 61 6c 75 | 65 28 63 6f 6e 74 72 6f |tCtlValu|e(contro|
|000031a0| 6c 48 61 6e 64 6c 65 28 | 69 74 65 6d 54 6f 43 68 |lHandle(|itemToCh|
|000031b0| 61 6e 67 65 29 2c 42 74 | 6e 4f 66 66 29 3b 0d 20 |ange),Bt|nOff);. |
|000031c0| 20 20 20 20 20 20 20 20 | 20 20 20 47 65 74 44 49 | | GetDI|
|000031d0| 74 65 6d 28 74 68 65 44 | 69 61 6c 6f 67 2c 54 65 |tem(theD|ialog,Te|
|000031e0| 78 74 41 70 70 42 75 74 | 74 6f 6e 2c 69 74 65 6d |xtAppBut|ton,item|
|000031f0| 54 79 70 65 2c 69 74 65 | 6d 54 6f 43 68 61 6e 67 |Type,ite|mToChang|
|00003200| 65 2c 69 74 65 6d 42 6f | 78 29 3b 0d 20 20 20 20 |e,itemBo|x);. |
|00003210| 20 20 20 20 20 20 20 20 | 53 65 74 43 74 6c 56 61 | |SetCtlVa|
|00003220| 6c 75 65 28 63 6f 6e 74 | 72 6f 6c 48 61 6e 64 6c |lue(cont|rolHandl|
|00003230| 65 28 69 74 65 6d 54 6f | 43 68 61 6e 67 65 29 2c |e(itemTo|Change),|
|00003240| 42 74 6e 4f 6e 29 3b 0d | 20 20 20 20 20 20 20 20 |BtnOn);.| |
|00003250| 20 20 20 20 54 65 78 74 | 4f 6e 6c 79 3a 3d 46 41 | Text|Only:=FA|
|00003260| 4c 53 45 3b 0d 20 20 20 | 20 20 20 20 20 20 20 20 |LSE;. | |
|00003270| 20 4d 79 53 46 48 6f 6f | 6b 3a 3d 20 72 65 44 72 | MySFHoo|k:= reDr|
|00003280| 61 77 4c 69 73 74 3b 09 | 7b 77 65 20 6d 75 73 74 |awList;.|{we must|
|00003290| 20 74 65 6c 6c 20 53 46 | 20 74 6f 20 72 65 64 72 | tell SF| to redr|
|000032a0| 61 77 20 74 68 65 20 6c | 69 73 74 7d 0d 20 20 20 |aw the l|ist}. |
|000032b0| 20 20 20 20 20 20 20 45 | 6e 64 3b 20 20 7b 69 66 | E|nd; {if|
|000032c0| 20 6e 6f 74 20 74 65 78 | 74 4f 6e 6c 79 7d 0d 20 | not tex|tOnly}. |
|000032d0| 20 20 20 20 20 20 20 45 | 6e 64 3b 20 20 7b 74 65 | E|nd; {te|
|000032e0| 78 74 41 70 70 42 75 74 | 74 6f 6e 7d 0d 20 20 20 |xtAppBut|ton}. |
|000032f0| 20 71 75 69 74 42 75 74 | 74 6f 6e 3a 20 20 4d 79 | quitBut|ton: My|
|00003300| 53 46 48 6f 6f 6b 3a 3d | 20 67 65 74 43 61 6e 63 |SFHook:=| getCanc|
|00003310| 65 6c 3b 09 7b 50 61 73 | 73 20 53 46 20 62 61 63 |el;.{Pas|s SF bac|
|00003320| 6b 20 61 20 27 63 61 6e | 63 65 6c 20 62 75 74 74 |k a 'can|cel butt|
|00003330| 6f 6e 27 7d 0d 7b 21 21 | 21 21 76 65 72 79 20 69 |on'}.{!!|!!very i|
|00003340| 6d 70 6f 72 74 61 6e 74 | 20 21 21 21 21 20 57 65 |mportant| !!!! We|
|00003350| 20 70 61 73 73 20 53 46 | 27 73 20 27 73 74 61 6e | pass SF|'s 'stan|
|00003360| 64 61 72 64 27 20 68 69 | 74 73 20 62 61 63 6b 20 |dard' hi|ts back |
|00003370| 74 6f 20 53 46 7d 0d 20 | 20 20 20 6f 74 68 65 72 |to SF}. | other|
|00003380| 77 69 73 65 20 20 42 65 | 67 69 6e 0d 20 20 20 20 |wise Be|gin. |
|00003390| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 4d 79 | | My|
|000033a0| 53 46 48 6f 6f 6b 3a 3d | 20 4d 79 53 46 49 74 65 |SFHook:=| MySFIte|
|000033b0| 6d 3b 09 7b 20 74 68 65 | 20 69 74 65 6d 20 68 69 |m;.{ the| item hi|
|000033c0| 74 20 77 61 73 20 6f 6e | 65 20 6f 66 20 53 46 27 |t was on|e of SF'|
|000033d0| 73 20 0d 09 09 09 09 09 | 09 73 74 61 6e 64 61 72 |s ......|.standar|
|000033e0| 64 20 69 74 65 6d 73 2e | 2e 2e 20 7d 0d 20 20 20 |d items.|.. }. |
|000033f0| 20 45 6e 64 3b 20 20 7b | 6f 74 68 65 72 77 69 73 | End; {|otherwis|
|00003400| 65 7d 09 09 09 7b 20 73 | 6f 20 6a 75 73 74 20 70 |e}...{ s|o just p|
|00003410| 61 73 73 20 69 74 20 62 | 61 63 6b 7d 0d 20 20 45 |ass it b|ack}. E|
|00003420| 6e 64 3b 20 20 7b 63 61 | 73 65 7d 0d 45 6e 64 3b |nd; {ca|se}.End;|
|00003430| 20 20 7b 4d 79 53 46 48 | 6f 6f 6b 7d 0d 7b 2d 2d | {MySFH|ook}.{--|
|00003440| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003450| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003460| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003470| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003480| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 7d 0d 46 55 4e |--------|---}.FUN|
|00003490| 43 54 49 4f 4e 20 53 46 | 46 69 6c 65 46 69 6c 74 |CTION SF|FileFilt|
|000034a0| 65 72 28 70 3a 70 61 72 | 6d 42 6c 6b 50 74 72 29 |er(p:par|mBlkPtr)|
|000034b0| 3a 62 6f 6f 6c 65 61 6e | 3b 20 7b 67 65 6e 65 72 |:boolean|; {gener|
|000034c0| 61 6c 20 73 74 72 61 74 | 65 67 79 20 2d 2d 20 63 |al strat|egy -- c|
|000034d0| 68 65 63 6b 20 76 61 6c | 75 65 0d 09 09 09 09 09 |heck val|ue......|
|000034e0| 09 20 20 20 6f 66 20 67 | 6c 6f 62 61 6c 20 76 61 |. of g|lobal va|
|000034f0| 72 74 65 78 74 4f 6e 6c | 79 20 74 6f 20 73 65 65 |rtextOnl|y to see|
|00003500| 0d 09 09 09 09 09 09 20 | 20 20 77 68 69 63 68 20 |....... | which |
|00003510| 66 69 6c 65 73 20 74 6f | 20 64 69 73 70 6c 61 79 |files to| display|
|00003520| 7d 0d 42 65 67 69 6e 20 | 7b 53 46 46 69 6c 65 46 |}.Begin |{SFFileF|
|00003530| 69 6c 74 65 72 7d 0d 20 | 20 53 46 46 69 6c 65 46 |ilter}. | SFFileF|
|00003540| 69 6c 74 65 72 3a 3d 20 | 54 52 55 45 3b 20 20 09 |ilter:= |TRUE; .|
|00003550| 09 09 7b 44 6f 6e 27 74 | 20 73 68 6f 77 20 69 74 |..{Don't| show it|
|00003560| 20 2d 2d 20 64 65 66 61 | 75 6c 74 7d 0d 20 20 69 | -- defa|ult}. i|
|00003570| 66 20 74 65 78 74 4f 6e | 6c 79 20 74 68 65 6e 0d |f textOn|ly then.|
|00003580| 20 20 20 20 20 20 69 66 | 20 70 5e 2e 69 6f 46 6c | if| p^.ioFl|
|00003590| 46 6e 64 72 49 6e 66 6f | 2e 66 64 54 79 70 65 20 |FndrInfo|.fdType |
|000035a0| 3d 20 27 54 45 58 54 27 | 20 74 68 65 6e 0d 20 20 |= 'TEXT'| then. |
|000035b0| 20 20 20 20 20 20 20 20 | 53 46 46 69 6c 65 46 69 | |SFFileFi|
|000035c0| 6c 74 65 72 3a 3d 20 46 | 41 4c 53 45 09 09 7b 53 |lter:= F|ALSE..{S|
|000035d0| 68 6f 77 20 69 74 7d 0d | 20 20 20 20 20 20 65 6c |how it}.| el|
|000035e0| 73 65 20 42 65 67 69 6e | 0d 20 20 20 20 20 20 45 |se Begin|. E|
|000035f0| 6e 64 20 20 7b 64 75 6d | 6d 79 20 65 6c 73 65 7d |nd {dum|my else}|
|00003600| 0d 20 20 65 6c 73 65 0d | 20 20 20 20 20 20 69 66 |. else.| if|
|00003610| 20 28 70 5e 2e 69 6f 46 | 6c 46 6e 64 72 49 6e 66 | (p^.ioF|lFndrInf|
|00003620| 6f 2e 66 64 54 79 70 65 | 20 3d 20 27 54 45 58 54 |o.fdType| = 'TEXT|
|00003630| 27 29 20 6f 72 20 28 70 | 5e 2e 69 6f 46 6c 46 6e |') or (p|^.ioFlFn|
|00003640| 64 72 49 6e 66 6f 2e 66 | 64 54 79 70 65 20 3d 20 |drInfo.f|dType = |
|00003650| 27 41 50 50 4c 27 29 20 | 74 68 65 6e 0d 20 20 20 |'APPL') |then. |
|00003660| 20 20 20 20 20 20 20 53 | 46 46 69 6c 65 46 69 6c | S|FFileFil|
|00003670| 74 65 72 3a 3d 20 46 41 | 4c 53 45 3b 09 09 7b 53 |ter:= FA|LSE;..{S|
|00003680| 68 6f 77 20 69 74 7d 0d | 45 6e 64 3b 20 20 7b 53 |how it}.|End; {S|
|00003690| 46 46 69 6c 65 46 69 6c | 74 65 72 7d 0d 7b 2d 2d |FFileFil|ter}.{--|
|000036a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036c0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 7d 0d 42 65 67 |--------|---}.Beg|
|000036f0| 69 6e 20 7b 6d 61 69 6e | 20 70 72 6f 67 72 61 6d |in {main| program|
|00003700| 7d 0d 20 20 20 49 6e 69 | 74 47 72 61 66 20 28 40 |}. Ini|tGraf (@|
|00003710| 74 68 65 50 6f 72 74 29 | 3b 0d 20 20 20 49 6e 69 |thePort)|;. Ini|
|00003720| 74 46 6f 6e 74 73 3b 0d | 20 20 20 49 6e 69 74 57 |tFonts;.| InitW|
|00003730| 69 6e 64 6f 77 73 3b 0d | 20 20 20 54 45 49 6e 69 |indows;.| TEIni|
|00003740| 74 3b 0d 20 20 20 49 6e | 69 74 44 69 61 6c 6f 67 |t;. In|itDialog|
|00003750| 73 20 28 6e 69 6c 29 3b | 0d 20 20 20 77 68 65 72 |s (nil);|. wher|
|00003760| 2e 68 3a 3d 38 30 3b 0d | 20 20 20 77 68 65 72 2e |.h:=80;.| wher.|
|00003770| 76 3a 3d 39 30 3b 0d 20 | 20 20 4e 75 6d 46 69 6c |v:=90;. | NumFil|
|00003780| 65 54 79 70 65 73 3a 3d | 20 2d 31 3b 20 20 09 09 |eTypes:=| -1; ..|
|00003790| 7b 44 69 73 70 6c 61 79 | 20 61 6c 6c 20 66 69 6c |{Display| all fil|
|000037a0| 65 73 7d 0d 7b 20 77 65 | 20 64 6f 6e 27 74 20 6e |es}.{ we| don't n|
|000037b0| 65 65 64 20 74 6f 20 69 | 6e 69 74 69 61 6c 69 7a |eed to i|nitializ|
|000037c0| 65 20 4d 79 46 69 6c 65 | 54 79 70 65 73 2c 20 62 |e MyFile|Types, b|
|000037d0| 65 63 61 75 73 65 20 77 | 65 20 77 61 6e 74 20 74 |ecause w|e want t|
|000037e0| 6f 20 67 65 74 20 61 20 | 63 68 61 6e 63 65 20 74 |o get a |chance t|
|000037f0| 6f 20 66 69 6c 74 65 72 | 20 65 76 65 72 79 20 66 |o filter| every f|
|00003800| 69 6c 65 20 20 20 20 6f | 6e 20 74 68 65 20 64 69 |ile o|n the di|
|00003810| 73 6b 20 69 6e 20 53 46 | 46 69 6c 65 46 69 6c 74 |sk in SF|FileFilt|
|00003820| 65 72 20 2d 20 77 65 20 | 77 69 6c 6c 20 64 65 63 |er - we |will dec|
|00003830| 69 64 65 20 77 68 61 74 | 20 74 6f 20 73 68 6f 77 |ide what| to show|
|00003840| 20 61 6e 64 20 77 68 61 | 74 20 6e 6f 74 20 74 6f | and wha|t not to|
|00003850| 2e 20 49 66 20 79 6f 75 | 20 77 61 6e 74 20 74 6f |. If you| want to|
|00003860| 20 66 69 6c 74 65 72 20 | 6a 75 73 74 20 63 65 72 | filter |just cer|
|00003870| 74 61 69 6e 20 74 79 70 | 65 73 20 6f 66 20 66 69 |tain typ|es of fi|
|00003880| 6c 65 73 20 62 79 20 6e | 61 6d 65 2c 20 79 6f 75 |les by n|ame, you|
|00003890| 20 77 6f 75 6c 64 20 73 | 65 74 20 75 70 20 4d 79 | would s|et up My|
|000038a0| 46 69 6c 65 54 79 70 65 | 73 20 61 6e 64 20 4e 75 |FileType|s and Nu|
|000038b0| 6d 46 69 6c 65 54 79 70 | 65 73 20 61 63 63 6f 72 |mFileTyp|es accor|
|000038c0| 64 69 6e 67 6c 79 7d 0d | 20 20 20 72 65 70 65 61 |dingly}.| repea|
|000038d0| 74 0d 09 7b 65 61 63 68 | 20 74 69 6d 65 20 53 46 |t..{each| time SF|
|000038e0| 50 47 65 74 46 69 6c 65 | 20 69 73 20 63 61 6c 6c |PGetFile| is call|
|000038f0| 65 64 2c 20 64 69 73 70 | 6c 61 79 20 77 69 6c 6c |ed, disp|lay will|
|00003900| 20 62 65 20 74 65 78 74 | 2d 6f 6e 6c 79 20 66 69 | be text|-only fi|
|00003910| 6c 65 73 7d 0d 20 20 20 | 20 20 20 20 74 65 78 74 |les}. | text|
|00003920| 4f 6e 6c 79 3a 3d 20 54 | 52 55 45 3b 0d 20 20 20 |Only:= T|RUE;. |
|00003930| 20 20 20 20 53 46 50 47 | 65 74 46 69 6c 65 20 28 | SFPG|etFile (|
|00003940| 77 68 65 72 2c 20 27 27 | 2c 20 40 53 46 46 69 6c |wher, ''|, @SFFil|
|00003950| 65 46 69 6c 74 65 72 2c | 20 4e 75 6d 46 69 6c 65 |eFilter,| NumFile|
|00003960| 54 79 70 65 73 2c 20 4d | 79 46 69 6c 65 54 79 70 |Types, M|yFileTyp|
|00003970| 65 73 2c 20 09 09 09 09 | 40 4d 79 53 46 48 6f 6f |es, ....|@MySFHoo|
|00003980| 6b 2c 72 65 70 6c 79 2c | 6d 79 44 4c 4f 47 49 44 |k,reply,|myDLOGID|
|00003990| 2c 6e 69 6c 29 3b 0d 20 | 20 20 75 6e 74 69 6c 20 |,nil);. | until |
|000039a0| 72 65 70 6c 79 2e 67 6f | 6f 64 20 3d 20 46 41 4c |reply.go|od = FAL|
|000039b0| 53 45 3b 0d 7b 75 6e 74 | 69 6c 20 61 20 63 61 6e |SE;.{unt|il a can|
|000039c0| 63 65 6c 20 62 75 74 74 | 6f 6e 20 68 69 74 20 28 |cel butt|on hit (|
|000039d0| 20 6f 72 20 61 20 51 75 | 69 74 20 62 75 74 74 6f | or a Qu|it butto|
|000039e0| 6e 20 2d 2d 20 74 68 61 | 6e 6b 73 20 74 6f 20 6f |n -- tha|nks to o|
|000039f0| 75 72 20 64 69 61 6c 6f | 67 20 68 6f 6f 6b 20 29 |ur dialo|g hook )|
|00003a00| 20 7d 0d 45 6e 64 2e 0d | 4d 50 57 20 43 20 53 6f | }.End..|MPW C So|
|00003a10| 75 72 63 65 0d 23 69 6e | 63 6c 75 64 65 20 3c 54 |urce.#in|clude <T|
|00003a20| 79 70 65 73 2e 68 3e 0d | 23 69 6e 63 6c 75 64 65 |ypes.h>.|#include|
|00003a30| 20 3c 51 75 69 63 6b 64 | 72 61 77 2e 68 3e 0d 23 | <Quickd|raw.h>.#|
|00003a40| 69 6e 63 6c 75 64 65 20 | 3c 52 65 73 6f 75 72 63 |include |<Resourc|
|00003a50| 65 73 2e 68 3e 0d 23 69 | 6e 63 6c 75 64 65 20 3c |es.h>.#i|nclude <|
|00003a60| 46 6f 6e 74 73 2e 68 3e | 0d 23 69 6e 63 6c 75 64 |Fonts.h>|.#includ|
|00003a70| 65 20 3c 57 69 6e 64 6f | 77 73 2e 68 3e 0d 23 69 |e <Windo|ws.h>.#i|
|00003a80| 6e 63 6c 75 64 65 20 3c | 4d 65 6e 75 73 2e 68 3e |nclude <|Menus.h>|
|00003a90| 0d 23 69 6e 63 6c 75 64 | 65 20 3c 54 65 78 74 45 |.#includ|e <TextE|
|00003aa0| 64 69 74 2e 68 3e 0d 23 | 69 6e 63 6c 75 64 65 20 |dit.h>.#|include |
|00003ab0| 3c 45 76 65 6e 74 73 2e | 68 3e 0d 23 69 6e 63 6c |<Events.|h>.#incl|
|00003ac0| 75 64 65 20 3c 44 69 61 | 6c 6f 67 73 2e 68 3e 0d |ude <Dia|logs.h>.|
|00003ad0| 23 69 6e 63 6c 75 64 65 | 20 3c 50 61 63 6b 61 67 |#include| <Packag|
|00003ae0| 65 73 2e 68 3e 0d 23 69 | 6e 63 6c 75 64 65 20 3c |es.h>.#i|nclude <|
|00003af0| 46 69 6c 65 73 2e 68 3e | 0d 23 69 6e 63 6c 75 64 |Files.h>|.#includ|
|00003b00| 65 20 3c 43 6f 6e 74 72 | 6f 6c 73 2e 68 3e 0d 23 |e <Contr|ols.h>.#|
|00003b10| 69 6e 63 6c 75 64 65 20 | 3c 54 6f 6f 6c 55 74 69 |include |<ToolUti|
|00003b20| 6c 73 2e 68 3e 0d 23 64 | 65 66 69 6e 65 09 74 65 |ls.h>.#d|efine.te|
|00003b30| 78 74 42 75 74 74 6f 6e | 09 31 31 09 20 2f 2a 44 |xtButton|.11. /*D|
|00003b40| 49 54 4c 20 69 74 65 6d | 20 6e 75 6d 62 65 72 20 |ITL item| number |
|00003b50| 6f 66 20 74 65 78 74 42 | 75 74 74 6f 6e 2a 2f 20 |of textB|utton*/ |
|00003b60| 20 20 20 20 20 20 0d 23 | 64 65 66 69 6e 65 09 74 | .#|define.t|
|00003b70| 65 78 74 41 70 70 42 75 | 74 74 6f 6e 09 31 32 09 |extAppBu|tton.12.|
|00003b80| 2f 2a 44 49 54 4c 20 69 | 74 65 6d 20 6e 75 6d 62 |/*DITL i|tem numb|
|00003b90| 65 72 20 6f 66 20 74 65 | 78 74 41 70 70 42 75 74 |er of te|xtAppBut|
|00003ba0| 74 6f 6e 2a 2f 20 20 20 | 20 20 20 20 20 0d 23 64 |ton*/ | .#d|
|00003bb0| 65 66 69 6e 65 09 71 75 | 69 74 42 75 74 74 6f 6e |efine.qu|itButton|
|00003bc0| 09 31 33 09 2f 2a 44 49 | 54 4c 20 69 74 65 6d 20 |.13./*DI|TL item |
|00003bd0| 6e 75 6d 62 65 72 20 6f | 66 20 71 75 69 74 42 75 |number o|f quitBu|
|00003be0| 74 74 6f 6e 2a 2f 20 20 | 20 20 20 20 20 20 0d 23 |tton*/ | .#|
|00003bf0| 64 65 66 69 6e 65 09 73 | 74 61 79 49 6e 53 46 09 |define.s|tayInSF.|
|00003c00| 30 09 2f 2a 69 66 20 77 | 65 20 77 61 6e 74 20 74 |0./*if w|e want t|
|00003c10| 6f 20 73 74 61 79 20 69 | 6e 20 53 46 20 61 66 74 |o stay i|n SF aft|
|00003c20| 65 72 20 67 65 74 74 69 | 6e 67 20 61 6e 0d 09 09 |er getti|ng an...|
|00003c30| 09 09 09 4f 70 65 6e 20 | 68 69 74 2c 20 77 65 20 |...Open |hit, we |
|00003c40| 63 61 6e 20 70 61 73 73 | 20 62 61 63 6b 20 61 20 |can pass| back a |
|00003c50| 30 20 66 72 6f 6d 20 6f | 75 72 0d 09 09 09 09 09 |0 from o|ur......|
|00003c60| 68 6f 6f 6b 20 20 28 6e | 6f 74 20 75 73 65 64 20 |hook (n|ot used |
|00003c70| 69 6e 20 74 68 69 73 20 | 65 78 61 6d 70 6c 65 29 |in this |example)|
|00003c80| 20 2a 2f 0d 20 20 0d 23 | 64 65 66 69 6e 65 09 66 | */. .#|define.f|
|00003c90| 69 72 73 74 54 69 6d 65 | 09 2d 31 09 2f 2a 20 74 |irstTime|.-1./* t|
|00003ca0| 68 65 20 66 69 72 73 74 | 20 74 69 6d 65 20 6f 75 |he first| time ou|
|00003cb0| 72 20 68 6f 6f 6b 20 69 | 73 20 63 61 6c 6c 65 64 |r hook i|s called|
|00003cc0| 2c 20 69 74 20 69 73 0d | 09 09 09 09 09 70 61 73 |, it is.|.....pas|
|00003cd0| 73 65 64 20 61 20 2d 31 | 2a 2f 0d 09 20 20 20 20 |sed a -1|*/.. |
|00003ce0| 20 20 20 20 0d 09 0d 23 | 64 65 66 69 6e 65 09 72 | ...#|define.r|
|00003cf0| 65 44 72 61 77 4c 69 73 | 74 09 31 30 31 09 2f 2a |eDrawLis|t.101./*|
|00003d00| 20 54 68 69 73 20 6c 69 | 6e 65 20 69 73 20 74 68 | This li|ne is th|
|00003d10| 65 20 6b 65 79 20 74 6f | 20 74 68 65 20 77 68 6f |e key to| the who|
|00003d20| 6c 65 0d 09 09 09 09 09 | 72 6f 75 74 69 6e 65 20 |le......|routine |
|00003d30| 74 68 65 20 6d 61 67 69 | 63 20 31 30 31 21 21 20 |the magi|c 101!! |
|00003d40| 72 65 74 75 72 6e 69 6e | 67 20 31 30 31 20 61 73 |returnin|g 101 as|
|00003d50| 0d 09 09 09 09 09 69 74 | 65 6d 20 6e 75 6d 62 65 |......it|em numbe|
|00003d60| 72 20 77 69 6c 6c 20 63 | 61 75 73 65 20 74 68 65 |r will c|ause the|
|00003d70| 20 66 69 6c 65 20 6c 69 | 73 74 20 74 6f 20 62 65 | file li|st to be|
|00003d80| 0d 09 09 09 09 09 72 65 | 63 61 6c 63 75 6c 61 74 |......re|calculat|
|00003d90| 65 64 2a 2f 20 20 20 20 | 20 20 20 20 0d 23 64 65 |ed*/ | .#de|
|00003da0| 66 69 6e 65 09 62 74 6e | 4f 6e 09 09 31 09 2f 2a |fine.btn|On..1./*|
|00003db0| 63 6f 6e 74 72 6f 6c 20 | 76 61 6c 75 65 20 66 6f |control |value fo|
|00003dc0| 72 20 6f 6e 2a 2f 09 20 | 20 20 20 20 20 20 20 0d |r on*/. | .|
|00003dd0| 23 64 65 66 69 6e 65 09 | 62 74 6e 4f 66 66 09 09 |#define.|btnOff..|
|00003de0| 30 09 2f 2a 63 6f 6e 74 | 72 6f 6c 20 76 61 6c 75 |0./*cont|rol valu|
|00003df0| 65 20 66 6f 72 20 6f 66 | 66 2a 2f 09 20 20 20 20 |e for of|f*/. |
|00003e00| 20 20 20 20 0d 23 64 65 | 66 69 6e 65 09 20 6d 79 | .#de|fine. my|
|00003e10| 44 4c 4f 47 49 44 09 31 | 32 38 09 2f 2a 72 65 73 |DLOGID.1|28./*res|
|00003e20| 6f 75 72 63 65 20 49 44 | 20 6f 66 20 6f 75 72 20 |ource ID| of our |
|00003e30| 44 4c 4f 47 20 66 6f 72 | 20 53 46 50 47 65 74 46 |DLOG for| SFPGetF|
|00003e40| 69 6c 65 2a 2f 0d 42 6f | 6f 6c 65 61 6e 09 09 74 |ile*/.Bo|olean..t|
|00003e50| 65 78 74 4f 6e 6c 79 3b | 09 20 20 20 20 20 20 20 |extOnly;|. |
|00003e60| 20 2f 2a 20 74 65 6c 6c | 73 20 75 73 20 77 68 69 | /* tell|s us whi|
|00003e70| 63 68 20 66 69 6c 65 73 | 20 61 72 65 20 63 75 72 |ch files| are cur|
|00003e80| 72 65 6e 74 6c 79 20 09 | 09 09 09 09 09 20 20 20 |rently .|..... |
|00003e90| 20 62 65 69 6e 67 20 64 | 69 73 70 6c 61 79 65 64 | being d|isplayed|
|00003ea0| 2a 2f 0d 20 0d 6d 61 69 | 6e 28 29 0d 7b 09 2f 2a |*/. .mai|n().{./*|
|00003eb0| 6d 61 69 6e 20 70 72 6f | 67 72 61 6d 2a 2f 0d 09 |main pro|gram*/..|
|00003ec0| 09 70 61 73 63 61 6c 20 | 73 68 6f 72 74 20 4d 79 |.pascal |short My|
|00003ed0| 53 46 48 6f 6f 6b 28 29 | 3b 20 20 0d 09 09 70 61 |SFHook()|; ...pa|
|00003ee0| 73 63 61 6c 20 42 6f 6f | 6c 65 61 6e 20 66 6c 46 |scal Boo|lean flF|
|00003ef0| 69 6c 74 65 72 28 29 3b | 0d 09 09 09 09 0d 09 09 |ilter();|........|
|00003f00| 50 6f 69 6e 74 20 20 09 | 77 68 65 72 3b 09 09 09 |Point .|wher;...|
|00003f10| 2f 2a 20 77 68 65 72 65 | 20 74 6f 20 64 69 73 70 |/* where| to disp|
|00003f20| 6c 61 79 20 64 69 61 6c | 6f 67 2a 2f 0d 09 09 53 |lay dial|og*/...S|
|00003f30| 46 52 65 70 6c 79 20 20 | 09 72 65 70 6c 79 3b 09 |FReply |.reply;.|
|00003f40| 20 20 20 20 20 20 20 20 | 09 2f 2a 20 72 65 70 6c | |./* repl|
|00003f50| 79 20 72 65 63 6f 72 64 | 20 2a 2f 0d 09 09 53 46 |y record| */...SF|
|00003f60| 54 79 70 65 4c 69 73 74 | 09 6d 79 46 69 6c 65 54 |TypeList|.myFileT|
|00003f70| 79 70 65 73 3b 20 20 20 | 20 20 20 09 2f 2a 20 77 |ypes; | ./* w|
|00003f80| 65 20 77 6f 6e 27 74 20 | 75 73 65 20 74 68 69 73 |e won't |use this|
|00003f90| 20 2a 2f 0d 09 09 73 68 | 6f 72 74 20 69 6e 74 20 | */...sh|ort int |
|00003fa0| 20 09 4e 75 6d 46 69 6c | 65 54 79 70 65 73 20 3d | .NumFil|eTypes =|
|00003fb0| 20 2d 31 3b 0d 20 20 20 | 20 49 6e 69 74 47 72 61 | -1;. | InitGra|
|00003fc0| 66 28 26 71 64 2e 74 68 | 65 50 6f 72 74 29 3b 0d |f(&qd.th|ePort);.|
|00003fd0| 20 20 20 20 49 6e 69 74 | 46 6f 6e 74 73 28 29 3b | Init|Fonts();|
|00003fe0| 0d 20 20 20 20 46 6c 75 | 73 68 45 76 65 6e 74 73 |. Flu|shEvents|
|00003ff0| 28 65 76 65 72 79 45 76 | 65 6e 74 2c 20 30 29 3b |(everyEv|ent, 0);|
|00004000| 0d 20 20 20 20 49 6e 69 | 74 57 69 6e 64 6f 77 73 |. Ini|tWindows|
|00004010| 28 29 3b 0d 20 20 20 20 | 54 45 49 6e 69 74 28 29 |();. |TEInit()|
|00004020| 3b 0d 20 20 20 20 49 6e | 69 74 44 69 61 6c 6f 67 |;. In|itDialog|
|00004030| 73 28 6e 69 6c 29 3b 0d | 20 20 20 20 49 6e 69 74 |s(nil);.| Init|
|00004040| 43 75 72 73 6f 72 28 29 | 3b 0d 20 20 20 77 68 65 |Cursor()|;. whe|
|00004050| 72 2e 68 3d 38 30 3b 0d | 20 20 20 77 68 65 72 2e |r.h=80;.| wher.|
|00004060| 76 3d 39 30 3b 0d 2f 2a | 20 77 65 20 64 6f 6e 27 |v=90;./*| we don'|
|00004070| 74 20 6e 65 65 64 20 74 | 6f 20 69 6e 69 74 69 61 |t need t|o initia|
|00004080| 6c 69 7a 65 20 4d 79 46 | 69 6c 65 54 79 70 65 73 |lize MyF|ileTypes|
|00004090| 2c 20 62 65 63 61 75 73 | 65 20 77 65 20 77 61 6e |, becaus|e we wan|
|000040a0| 74 20 74 6f 20 67 65 74 | 20 61 20 63 68 61 6e 63 |t to get| a chanc|
|000040b0| 65 20 74 6f 20 66 69 6c | 74 65 72 20 65 76 65 72 |e to fil|ter ever|
|000040c0| 79 20 66 69 6c 65 20 6f | 6e 20 20 74 68 65 20 64 |y file o|n the d|
|000040d0| 69 73 6b 20 69 6e 20 66 | 6c 46 69 6c 74 65 72 20 |isk in f|lFilter |
|000040e0| 2d 20 77 65 20 77 69 6c | 6c 20 64 65 63 69 64 65 |- we wil|l decide|
|000040f0| 20 77 68 61 74 20 74 6f | 20 73 68 6f 77 20 61 6e | what to| show an|
|00004100| 64 20 77 68 61 74 20 6e | 6f 74 20 74 6f 2e 20 69 |d what n|ot to. i|
|00004110| 66 20 79 6f 75 20 77 61 | 6e 74 20 74 6f 20 66 69 |f you wa|nt to fi|
|00004120| 6c 74 65 72 20 6a 75 73 | 74 20 63 65 72 74 61 69 |lter jus|t certai|
|00004130| 6e 20 74 79 70 65 73 20 | 6f 66 20 66 69 6c 65 73 |n types |of files|
|00004140| 20 62 79 20 6e 61 6d 65 | 2c 20 79 6f 75 20 77 6f | by name|, you wo|
|00004150| 75 6c 64 20 73 65 74 20 | 75 70 20 4d 79 46 69 6c |uld set |up MyFil|
|00004160| 65 54 79 70 65 73 20 61 | 6e 64 20 4e 75 6d 46 69 |eTypes a|nd NumFi|
|00004170| 6c 65 54 79 70 65 73 20 | 61 63 63 6f 72 64 69 6e |leTypes |accordin|
|00004180| 67 6c 79 2a 2f 0d 20 20 | 20 64 6f 20 7b 0d 09 74 |gly*/. | do {..t|
|00004190| 65 78 74 4f 6e 6c 79 3d | 20 74 72 75 65 3b 09 20 |extOnly=| true;. |
|000041a0| 2f 2a 65 61 63 68 20 74 | 69 6d 65 20 53 46 50 47 |/*each t|ime SFPG|
|000041b0| 65 74 46 69 6c 65 20 69 | 73 20 63 61 6c 6c 65 64 |etFile i|s called|
|000041c0| 2c 20 69 6e 69 74 69 61 | 6c 0d 09 09 09 09 09 64 |, initia|l......d|
|000041d0| 69 73 70 6c 61 79 20 77 | 69 6c 6c 20 62 65 20 74 |isplay w|ill be t|
|000041e0| 65 78 74 2d 6f 6e 6c 79 | 20 66 69 6c 65 73 2a 2f |ext-only| files*/|
|000041f0| 0d 20 20 20 20 20 20 20 | 53 46 50 47 65 74 46 69 |. |SFPGetFi|
|00004200| 6c 65 28 26 77 68 65 72 | 2c 22 22 2c 66 6c 46 69 |le(&wher|,"",flFi|
|00004210| 6c 74 65 72 2c 20 4e 75 | 6d 46 69 6c 65 54 79 70 |lter, Nu|mFileTyp|
|00004220| 65 73 2c 6d 79 46 69 6c | 65 54 79 70 65 73 2c 0d |es,myFil|eTypes,.|
|00004230| 09 09 09 4d 79 53 46 48 | 6f 6f 6b 2c 20 26 72 65 |...MySFH|ook, &re|
|00004240| 70 6c 79 2c 6d 79 44 4c | 4f 47 49 44 2c 6e 69 6c |ply,myDL|OGID,nil|
|00004250| 29 3b 0d 20 20 20 7d 20 | 77 68 69 6c 65 20 28 72 |);. } |while (r|
|00004260| 65 70 6c 79 2e 67 6f 6f | 64 29 3b 20 20 20 20 2f |eply.goo|d); /|
|00004270| 2a 75 6e 74 69 6c 20 77 | 65 20 67 65 74 20 61 20 |*until w|e get a |
|00004280| 63 61 6e 63 65 6c 20 62 | 75 74 74 6f 6e 20 68 69 |cancel b|utton hi|
|00004290| 74 0d 09 09 09 09 20 28 | 6f 72 20 61 20 51 75 69 |t..... (|or a Qui|
|000042a0| 74 20 62 75 74 74 6f 6e | 20 69 6e 20 74 68 69 73 |t button| in this|
|000042b0| 20 63 61 73 65 20 29 20 | 2a 2f 0d 7d 20 2f 2a 20 | case ) |*/.} /* |
|000042c0| 6d 61 69 6e 20 2a 2f 0d | 70 61 73 63 61 6c 20 73 |main */.|pascal s|
|000042d0| 68 6f 72 74 20 4d 79 53 | 46 48 6f 6f 6b 28 73 68 |hort MyS|FHook(sh|
|000042e0| 6f 72 74 20 4d 79 53 46 | 49 74 65 6d 2c 44 69 61 |ort MySF|Item,Dia|
|000042f0| 6c 6f 67 50 74 72 20 74 | 68 65 44 69 61 6c 6f 67 |logPtr t|heDialog|
|00004300| 29 0d 7b 0d 48 61 6e 64 | 6c 65 20 20 69 74 65 6d |).{.Hand|le item|
|00004310| 54 6f 43 68 61 6e 67 65 | 3b 09 20 20 20 20 20 20 |ToChange|;. |
|00004320| 20 20 2f 2a 6e 65 65 64 | 65 64 20 66 6f 72 20 47 | /*need|ed for G|
|00004330| 65 74 44 49 74 65 6d 20 | 61 6e 64 20 53 65 74 43 |etDItem |and SetC|
|00004340| 74 6c 56 61 6c 75 65 2a | 2f 0d 52 65 63 74 09 69 |tlValue*|/.Rect.i|
|00004350| 74 65 6d 42 6f 78 3b 09 | 09 20 20 20 20 20 20 20 |temBox;.|. |
|00004360| 20 2f 2a 6e 65 65 64 65 | 64 20 66 6f 72 20 47 65 | /*neede|d for Ge|
|00004370| 74 44 49 74 65 6d 2a 2f | 0d 73 68 6f 72 74 09 69 |tDItem*/|.short.i|
|00004380| 74 65 6d 54 79 70 65 3b | 09 20 20 20 20 20 20 20 |temType;|. |
|00004390| 09 09 2f 2a 6e 65 65 64 | 65 64 20 66 6f 72 20 47 |../*need|ed for G|
|000043a0| 65 74 44 49 74 65 6d 2a | 2f 0d 63 68 61 72 09 62 |etDItem*|/.char.b|
|000043b0| 75 74 74 6f 6e 54 69 74 | 6c 65 5b 32 35 36 5d 3b |uttonTit|le[256];|
|000043c0| 09 09 2f 2a 6e 65 65 64 | 65 64 20 66 6f 72 20 47 |../*need|ed for G|
|000043d0| 65 74 49 6e 64 53 74 72 | 69 6e 67 2a 2f 0d 20 20 |etIndStr|ing*/. |
|000043e0| 73 77 69 74 63 68 20 28 | 4d 79 53 46 49 74 65 6d |switch (|MySFItem|
|000043f0| 29 0d 20 20 7b 0d 09 63 | 61 73 65 20 66 69 72 73 |). {..c|ase firs|
|00004400| 74 54 69 6d 65 3a 09 20 | 20 20 20 20 20 0d 09 09 |tTime:. | ...|
|00004410| 2f 2a 20 62 65 66 6f 72 | 65 20 74 68 65 20 64 69 |/* befor|e the di|
|00004420| 61 6c 6f 67 20 69 73 20 | 64 72 61 77 6e 2c 20 6f |alog is |drawn, o|
|00004430| 75 72 20 68 6f 6f 6b 20 | 67 65 74 73 20 63 61 6c |ur hook |gets cal|
|00004440| 6c 65 64 20 77 69 74 68 | 20 61 20 2d 31 0d 09 09 |led with| a -1...|
|00004450| 20 28 66 69 72 73 74 54 | 69 6d 65 29 2e 2e 2e 20 | (firstT|ime)... |
|00004460| 61 73 20 74 68 65 20 69 | 74 65 6d 20 73 6f 20 77 |as the i|tem so w|
|00004470| 65 20 63 61 6e 20 63 68 | 61 6e 67 65 20 74 68 69 |e can ch|ange thi|
|00004480| 6e 67 73 20 6c 69 6b 65 | 20 62 75 74 74 6f 6e 0d |ngs like| button.|
|00004490| 09 09 20 74 69 74 6c 65 | 73 2c 20 65 74 63 2e 20 |.. title|s, etc. |
|000044a0| 48 65 72 65 20 77 65 20 | 73 65 74 20 74 68 65 20 |Here we |set the |
|000044b0| 74 65 78 74 41 70 70 42 | 75 74 74 6f 6e 20 74 6f |textAppB|utton to|
|000044c0| 20 4f 46 46 2c 20 74 68 | 65 20 0d 09 09 20 74 65 | OFF, th|e ... te|
|000044d0| 78 74 42 75 74 74 6f 6e | 20 74 6f 20 4f 4e 2a 2f |xtButton| to ON*/|
|000044e0| 0d 09 09 47 65 74 44 49 | 74 65 6d 28 74 68 65 44 |...GetDI|tem(theD|
|000044f0| 69 61 6c 6f 67 2c 74 65 | 78 74 41 70 70 42 75 74 |ialog,te|xtAppBut|
|00004500| 74 6f 6e 2c 26 69 74 65 | 6d 54 79 70 65 2c 26 69 |ton,&ite|mType,&i|
|00004510| 74 65 6d 54 6f 43 68 61 | 6e 67 65 2c 26 69 74 65 |temToCha|nge,&ite|
|00004520| 6d 42 6f 78 29 3b 0d 09 | 09 53 65 74 43 74 6c 56 |mBox);..|.SetCtlV|
|00004530| 61 6c 75 65 28 69 74 65 | 6d 54 6f 43 68 61 6e 67 |alue(ite|mToChang|
|00004540| 65 2c 62 74 6e 4f 66 66 | 29 3b 0d 09 09 47 65 74 |e,btnOff|);...Get|
|00004550| 44 49 74 65 6d 28 74 68 | 65 44 69 61 6c 6f 67 2c |DItem(th|eDialog,|
|00004560| 74 65 78 74 42 75 74 74 | 6f 6e 2c 26 69 74 65 6d |textButt|on,&item|
|00004570| 54 79 70 65 2c 26 69 74 | 65 6d 54 6f 43 68 61 6e |Type,&it|emToChan|
|00004580| 67 65 2c 26 69 74 65 6d | 42 6f 78 29 3b 0d 09 09 |ge,&item|Box);...|
|00004590| 53 65 74 43 74 6c 56 61 | 6c 75 65 28 69 74 65 6d |SetCtlVa|lue(item|
|000045a0| 54 6f 43 68 61 6e 67 65 | 2c 62 74 6e 4f 6e 29 3b |ToChange|,btnOn);|
|000045b0| 0d 09 09 2f 2a 67 65 74 | 20 74 68 65 20 62 75 74 |.../*get| the but|
|000045c0| 74 6f 6e 20 74 69 74 6c | 65 20 66 72 6f 6d 20 61 |ton titl|e from a|
|000045d0| 20 72 65 73 6f 75 72 63 | 65 20 66 69 6c 65 2a 2f | resourc|e file*/|
|000045e0| 0d 09 09 47 65 74 49 6e | 64 53 74 72 69 6e 67 28 |...GetIn|dString(|
|000045f0| 28 63 68 61 72 20 2a 29 | 62 75 74 74 6f 6e 54 69 |(char *)|buttonTi|
|00004600| 74 6c 65 2c 32 35 36 2c | 31 29 3b 09 0d 09 09 69 |tle,256,|1);....i|
|00004610| 66 20 28 62 75 74 74 6f | 6e 54 69 74 6c 65 5b 30 |f (butto|nTitle[0|
|00004620| 5d 20 21 3d 20 30 29 09 | 2f 2a 20 63 68 65 63 6b |] != 0).|/* check|
|00004630| 20 74 68 65 20 6c 65 6e | 67 74 68 20 6f 66 20 74 | the len|gth of t|
|00004640| 68 65 20 70 2d 73 74 72 | 69 6e 67 0d 09 09 09 09 |he p-str|ing.....|
|00004650| 09 09 74 6f 20 73 65 65 | 20 69 66 20 77 65 20 67 |..to see| if we g|
|00004660| 6f 74 20 74 68 65 20 72 | 65 73 6f 75 72 63 65 2a |ot the r|esource*|
|00004670| 2f 0d 09 09 7b 0d 09 0d | 09 2f 2a 67 65 74 20 61 |/...{...|./*get a|
|00004680| 20 68 61 6e 64 6c 65 20 | 74 6f 20 74 68 65 20 6f | handle |to the o|
|00004690| 70 65 6e 20 62 75 74 74 | 6f 6e 2a 2f 09 09 47 65 |pen butt|on*/..Ge|
|000046a0| 74 44 49 74 65 6d 28 74 | 68 65 44 69 61 6c 6f 67 |tDItem(t|heDialog|
|000046b0| 2c 67 65 74 4f 70 65 6e | 2c 26 69 74 65 6d 54 79 |,getOpen|,&itemTy|
|000046c0| 70 65 2c 26 69 74 65 6d | 54 6f 43 68 61 6e 67 65 |pe,&item|ToChange|
|000046d0| 2c 26 69 74 65 6d 42 6f | 78 29 3b 20 0d 09 09 09 |,&itemBo|x); ....|
|000046e0| 53 65 74 43 54 69 74 6c | 65 28 69 74 65 6d 54 6f |SetCTitl|e(itemTo|
|000046f0| 43 68 61 6e 67 65 2c 62 | 75 74 74 6f 6e 54 69 74 |Change,b|uttonTit|
|00004700| 6c 65 29 3b 0d 09 20 20 | 09 7d 20 20 09 09 09 20 |le);.. |.} ... |
|00004710| 2f 2a 69 66 20 77 65 20 | 63 61 6e 27 74 20 67 65 |/*if we |can't ge|
|00004720| 74 20 74 68 65 20 72 65 | 73 6f 75 72 63 65 2c 20 |t the re|source, |
|00004730| 77 65 20 6a 75 73 74 0d | 09 09 09 09 09 20 20 77 |we just.|..... w|
|00004740| 6f 6e 27 74 20 63 68 61 | 6e 67 65 20 74 68 65 20 |on't cha|nge the |
|00004750| 6f 70 65 6e 20 62 75 74 | 74 6f 6e 27 73 20 74 69 |open but|ton's ti|
|00004760| 74 6c 65 2a 2f 0d 09 09 | 72 65 74 75 72 6e 20 4d |tle*/...|return M|
|00004770| 79 53 46 49 74 65 6d 3b | 09 20 2f 2a 70 61 73 73 |ySFItem;|. /*pass|
|00004780| 20 62 61 63 6b 20 74 68 | 65 20 73 61 6d 65 20 69 | back th|e same i|
|00004790| 74 65 6d 20 77 65 20 77 | 65 72 65 20 73 65 6e 74 |tem we w|ere sent|
|000047a0| 2a 2f 0d 09 09 62 72 65 | 61 6b 3b 0d 2f 2a 48 65 |*/...bre|ak;./*He|
|000047b0| 72 65 20 77 65 20 74 75 | 72 6e 20 74 68 65 20 74 |re we tu|rn the t|
|000047c0| 65 78 74 41 70 70 42 75 | 74 74 6f 6e 20 4f 46 46 |extAppBu|tton OFF|
|000047d0| 2c 20 74 68 65 20 74 65 | 78 74 42 75 74 74 6f 6e |, the te|xtButton|
|000047e0| 20 4f 4e 20 61 6e 64 20 | 72 65 64 72 61 77 20 74 | ON and |redraw t|
|000047f0| 68 65 20 6c 69 73 74 2a | 2f 0d 20 20 20 20 63 61 |he list*|/. ca|
|00004800| 73 65 20 74 65 78 74 42 | 75 74 74 6f 6e 3a 20 0d |se textB|utton: .|
|00004810| 20 20 20 20 20 20 20 20 | 69 66 20 28 21 74 65 78 | |if (!tex|
|00004820| 74 4f 6e 6c 79 29 20 7b | 0d 20 20 20 20 20 20 20 |tOnly) {|. |
|00004830| 20 20 20 20 20 09 09 47 | 65 74 44 49 74 65 6d 28 | ..G|etDItem(|
|00004840| 74 68 65 44 69 61 6c 6f | 67 2c 74 65 78 74 41 70 |theDialo|g,textAp|
|00004850| 70 42 75 74 74 6f 6e 2c | 26 69 74 65 6d 54 79 70 |pButton,|&itemTyp|
|00004860| 65 2c 26 69 74 65 6d 54 | 6f 43 68 61 6e 67 65 2c |e,&itemT|oChange,|
|00004870| 26 69 74 65 6d 42 6f 78 | 29 3b 0d 20 20 20 20 20 |&itemBox|);. |
|00004880| 20 20 09 53 65 74 43 74 | 6c 56 61 6c 75 65 28 69 | .SetCt|lValue(i|
|00004890| 74 65 6d 54 6f 43 68 61 | 6e 67 65 2c 62 74 6e 4f |temToCha|nge,btnO|
|000048a0| 66 66 29 3b 0d 20 20 20 | 20 20 20 20 20 20 20 20 |ff);. | |
|000048b0| 20 09 09 09 09 09 09 09 | 47 65 74 44 49 74 65 6d | .......|GetDItem|
|000048c0| 28 74 68 65 44 69 61 6c | 6f 67 2c 74 65 78 74 42 |(theDial|og,textB|
|000048d0| 75 74 74 6f 6e 2c 26 69 | 74 65 6d 54 79 70 65 2c |utton,&i|temType,|
|000048e0| 26 69 74 65 6d 54 6f 43 | 68 61 6e 67 65 2c 26 69 |&itemToC|hange,&i|
|000048f0| 74 65 6d 42 6f 78 29 3b | 0d 20 20 20 20 20 20 20 |temBox);|. |
|00004900| 20 20 20 20 20 09 53 65 | 74 43 74 6c 56 61 6c 75 | .Se|tCtlValu|
|00004910| 65 28 69 74 65 6d 54 6f | 43 68 61 6e 67 65 2c 62 |e(itemTo|Change,b|
|00004920| 74 6e 4f 6e 29 3b 0d 20 | 20 20 20 20 20 20 20 20 |tnOn);. | |
|00004930| 20 20 20 09 74 65 78 74 | 4f 6e 6c 79 3d 74 72 75 | .text|Only=tru|
|00004940| 65 3b 0d 20 20 20 20 20 | 20 20 20 20 20 20 20 09 |e;. | .|
|00004950| 09 72 65 74 75 72 6e 28 | 72 65 44 72 61 77 4c 69 |.return(|reDrawLi|
|00004960| 73 74 29 3b 09 2f 2a 6d | 75 73 74 20 74 65 6c 6c |st);./*m|ust tell|
|00004970| 20 53 46 20 74 6f 20 72 | 65 64 72 61 77 20 74 68 | SF to r|edraw th|
|00004980| 65 20 6c 69 73 74 2a 2f | 0d 20 20 20 20 20 20 20 |e list*/|. |
|00004990| 20 20 20 20 09 7d 20 20 | 09 09 09 09 2f 2a 69 66 | .} |..../*if|
|000049a0| 20 21 74 65 78 74 4f 6e | 6c 79 2a 2f 0d 09 09 72 | !textOn|ly*/...r|
|000049b0| 65 74 75 72 6e 20 4d 79 | 53 46 49 74 65 6d 3b 0d |eturn My|SFItem;.|
|000049c0| 09 09 62 72 65 61 6b 3b | 20 09 09 09 2f 2a 48 65 |..break;| .../*He|
|000049d0| 72 65 20 77 65 20 77 69 | 6c 6c 20 74 75 72 6e 20 |re we wi|ll turn |
|000049e0| 74 68 65 20 74 65 78 74 | 42 75 74 74 6f 6e 0d 09 |the text|Button..|
|000049f0| 09 09 09 09 09 4f 46 46 | 2c 20 74 68 65 20 74 65 |.....OFF|, the te|
|00004a00| 78 74 41 70 70 42 75 74 | 74 6f 6e 20 4f 4e 20 61 |xtAppBut|ton ON a|
|00004a10| 6e 64 20 72 65 64 72 61 | 77 0d 09 09 09 09 09 09 |nd redra|w.......|
|00004a20| 74 68 65 20 6c 69 73 74 | 2a 2f 0d 20 20 20 20 63 |the list|*/. c|
|00004a30| 61 73 65 20 74 65 78 74 | 41 70 70 42 75 74 74 6f |ase text|AppButto|
|00004a40| 6e 3a 0d 20 20 20 20 20 | 20 20 20 69 66 20 28 74 |n:. | if (t|
|00004a50| 65 78 74 4f 6e 6c 79 29 | 0d 20 20 20 20 20 20 20 |extOnly)|. |
|00004a60| 09 20 7b 20 20 20 0d 09 | 09 09 47 65 74 44 49 74 |. { ..|..GetDIt|
|00004a70| 65 6d 28 74 68 65 44 69 | 61 6c 6f 67 2c 74 65 78 |em(theDi|alog,tex|
|00004a80| 74 42 75 74 74 6f 6e 2c | 26 69 74 65 6d 54 79 70 |tButton,|&itemTyp|
|00004a90| 65 2c 26 69 74 65 6d 54 | 6f 43 68 61 6e 67 65 2c |e,&itemT|oChange,|
|00004aa0| 26 69 74 65 6d 42 6f 78 | 29 3b 0d 20 20 20 20 20 |&itemBox|);. |
|00004ab0| 20 20 20 20 20 20 20 09 | 09 53 65 74 43 74 6c 56 | .|.SetCtlV|
|00004ac0| 61 6c 75 65 28 69 74 65 | 6d 54 6f 43 68 61 6e 67 |alue(ite|mToChang|
|00004ad0| 65 2c 62 74 6e 4f 66 66 | 29 3b 0d 20 20 20 20 20 |e,btnOff|);. |
|00004ae0| 20 20 20 20 20 20 20 09 | 09 47 65 74 44 49 74 65 | .|.GetDIte|
|00004af0| 6d 28 74 68 65 44 69 61 | 6c 6f 67 2c 74 65 78 74 |m(theDia|log,text|
|00004b00| 41 70 70 42 75 74 74 6f | 6e 2c 26 69 74 65 6d 54 |AppButto|n,&itemT|
|00004b10| 79 70 65 2c 26 69 74 65 | 6d 54 6f 43 68 61 6e 67 |ype,&ite|mToChang|
|00004b20| 65 2c 26 69 74 65 6d 42 | 6f 78 29 3b 0d 20 20 20 |e,&itemB|ox);. |
|00004b30| 20 20 20 20 20 20 20 20 | 20 09 09 53 65 74 43 74 | | ..SetCt|
|00004b40| 6c 56 61 6c 75 65 28 69 | 74 65 6d 54 6f 43 68 61 |lValue(i|temToCha|
|00004b50| 6e 67 65 2c 62 74 6e 4f | 6e 29 3b 0d 20 20 20 20 |nge,btnO|n);. |
|00004b60| 20 20 20 20 20 20 20 20 | 09 09 74 65 78 74 4f 6e | |..textOn|
|00004b70| 6c 79 3d 66 61 6c 73 65 | 3b 0d 20 20 20 20 20 20 |ly=false|;. |
|00004b80| 20 20 20 20 20 20 09 09 | 72 65 74 75 72 6e 28 72 | ..|return(r|
|00004b90| 65 44 72 61 77 4c 69 73 | 74 29 3b 09 2f 2a 20 6d |eDrawLis|t);./* m|
|00004ba0| 75 73 74 20 74 65 6c 6c | 20 53 46 20 74 6f 20 72 |ust tell| SF to r|
|00004bb0| 65 64 72 61 77 20 74 68 | 65 20 6c 69 73 74 2a 2f |edraw th|e list*/|
|00004bc0| 0d 20 20 20 20 20 20 20 | 09 7d 20 20 2f 2a 69 66 |. |.} /*if|
|00004bd0| 20 6e 6f 74 20 74 65 78 | 74 4f 6e 6c 79 2a 2f 0d | not tex|tOnly*/.|
|00004be0| 09 09 72 65 74 75 72 6e | 20 4d 79 53 46 49 74 65 |..return| MySFIte|
|00004bf0| 6d 3b 09 20 2f 2a 70 61 | 73 73 20 62 61 63 6b 20 |m;. /*pa|ss back |
|00004c00| 74 68 65 20 73 61 6d 65 | 20 69 74 65 6d 20 77 65 |the same| item we|
|00004c10| 20 77 65 72 65 20 73 65 | 6e 74 2a 2f 0d 09 09 62 | were se|nt*/...b|
|00004c20| 72 65 61 6b 3b 0d 20 20 | 20 20 63 61 73 65 20 71 |reak;. | case q|
|00004c30| 75 69 74 42 75 74 74 6f | 6e 3a 09 20 0d 09 09 72 |uitButto|n:. ...r|
|00004c40| 65 74 75 72 6e 28 67 65 | 74 43 61 6e 63 65 6c 29 |eturn(ge|tCancel)|
|00004c50| 3b 09 2f 2a 50 61 73 73 | 20 53 46 20 62 61 63 6b |;./*Pass| SF back|
|00004c60| 20 61 20 27 63 61 6e 63 | 65 6c 20 62 75 74 74 6f | a 'canc|el butto|
|00004c70| 6e 27 2a 2f 0d 2f 2a 21 | 21 21 76 65 72 79 20 69 |n'*/./*!|!!very i|
|00004c80| 6d 70 6f 72 74 61 6e 74 | 20 21 21 21 21 20 57 65 |mportant| !!!! We|
|00004c90| 20 6d 75 73 74 20 70 61 | 73 73 20 53 46 27 73 20 | must pa|ss SF's |
|00004ca0| 27 73 74 61 6e 64 61 72 | 64 27 20 69 74 65 6d 20 |'standar|d' item |
|00004cb0| 68 69 74 73 20 62 61 63 | 6b 20 74 6f 20 53 46 2a |hits bac|k to SF*|
|00004cc0| 2f 0d 20 20 20 20 64 65 | 66 61 75 6c 74 3a 0d 20 |/. de|fault:. |
|00004cd0| 20 20 20 20 20 20 20 72 | 65 74 75 72 6e 28 4d 79 | r|eturn(My|
|00004ce0| 53 46 49 74 65 6d 29 3b | 09 2f 2a 20 74 68 65 20 |SFItem);|./* the |
|00004cf0| 69 74 65 6d 20 77 61 73 | 20 6f 6e 65 20 6f 66 20 |item was| one of |
|00004d00| 53 46 27 73 20 73 74 61 | 6e 64 61 72 64 20 69 74 |SF's sta|ndard it|
|00004d10| 65 6d 73 2e 2e 2e 20 2a | 2f 0d 20 20 7d 20 20 2f |ems... *|/. } /|
|00004d20| 2a 73 77 69 74 63 68 2a | 2f 0d 20 20 09 72 65 74 |*switch*|/. .ret|
|00004d30| 75 72 6e 28 4d 79 53 46 | 49 74 65 6d 29 3b 09 2f |urn(MySF|Item);./|
|00004d40| 2a 20 72 65 74 75 72 6e | 20 77 68 61 74 20 77 65 |* return| what we|
|00004d50| 20 67 6f 74 20 2a 2f 0d | 7d 20 20 2f 2a 4d 79 53 | got */.|} /*MyS|
|00004d60| 46 48 6f 6f 6b 2a 2f 0d | 70 61 73 63 61 6c 20 42 |FHook*/.|pascal B|
|00004d70| 6f 6f 6c 65 61 6e 20 66 | 6c 46 69 6c 74 65 72 28 |oolean f|lFilter(|
|00004d80| 70 62 29 0d 46 69 6c 65 | 50 61 72 61 6d 09 2a 70 |pb).File|Param.*p|
|00004d90| 62 3b 0d 20 0d 7b 0d 2f | 2a 20 69 73 20 74 68 69 |b;. .{./|* is thi|
|00004da0| 73 20 67 72 6f 73 73 20 | 6f 72 20 77 68 61 74 3f |s gross |or what?|
|00004db0| 3f 3f 20 2a 2f 0d 72 65 | 74 75 72 6e 28 28 74 65 |?? */.re|turn((te|
|00004dc0| 78 74 4f 6e 6c 79 29 20 | 3f 20 28 28 70 62 2d 3e |xtOnly) |? ((pb->|
|00004dd0| 69 6f 46 6c 46 6e 64 72 | 49 6e 66 6f 2e 66 64 54 |ioFlFndr|Info.fdT|
|00004de0| 79 70 65 29 20 21 3d 20 | 27 54 45 58 54 27 29 20 |ype) != |'TEXT') |
|00004df0| 3a 0d 09 28 28 70 62 2d | 3e 69 6f 46 6c 46 6e 64 |:..((pb-|>ioFlFnd|
|00004e00| 72 49 6e 66 6f 2e 66 64 | 54 79 70 65 29 20 21 3d |rInfo.fd|Type) !=|
|00004e10| 20 27 54 45 58 54 27 29 | 20 26 26 20 0d 09 28 28 | 'TEXT')| && ..((|
|00004e20| 70 62 2d 3e 69 6f 46 6c | 46 6e 64 72 49 6e 66 6f |pb->ioFl|FndrInfo|
|00004e30| 2e 66 64 54 79 70 65 29 | 20 21 3d 20 27 41 50 50 |.fdType)| != 'APP|
|00004e40| 4c 27 29 29 3b 0d 7d 20 | 20 2f 2a 66 6c 46 69 6c |L'));.} | /*flFil|
|00004e50| 74 65 72 2a 2f 0d 52 65 | 7a 20 49 6e 70 75 74 20 |ter*/.Re|z Input |
|00004e60| 46 69 6c 65 0d 23 69 6e | 63 6c 75 64 65 20 22 74 |File.#in|clude "t|
|00004e70| 79 70 65 73 2e 72 22 0d | 72 65 73 6f 75 72 63 65 |ypes.r".|resource|
|00004e80| 20 27 53 54 52 23 27 20 | 28 32 35 36 29 20 7b 0d | 'STR#' |(256) {.|
|00004e90| 09 7b 0d 09 09 22 4d 79 | 4f 70 65 6e 22 0d 09 7d |.{..."My|Open"..}|
|00004ea0| 0d 7d 3b 0d 72 65 73 6f | 75 72 63 65 20 27 44 4c |.};.reso|urce 'DL|
|00004eb0| 4f 47 27 20 28 31 32 38 | 2c 20 70 75 72 67 65 61 |OG' (128|, purgea|
|00004ec0| 62 6c 65 29 20 7b 0d 09 | 7b 30 2c 20 30 2c 20 32 |ble) {..|{0, 0, 2|
|00004ed0| 30 30 2c 20 33 34 39 7d | 2c 0d 09 64 42 6f 78 50 |00, 349}|,..dBoxP|
|00004ee0| 72 6f 63 2c 0d 09 69 6e | 76 69 73 69 62 6c 65 2c |roc,..in|visible,|
|00004ef0| 0d 09 6e 6f 47 6f 41 77 | 61 79 2c 0d 09 30 78 30 |..noGoAw|ay,..0x0|
|00004f00| 2c 0d 09 31 32 38 2c 0d | 09 22 4d 79 47 46 22 0d |,..128,.|."MyGF".|
|00004f10| 7d 3b 0d 72 65 73 6f 75 | 72 63 65 20 27 44 49 54 |};.resou|rce 'DIT|
|00004f20| 4c 27 20 28 31 32 38 2c | 20 70 75 72 67 65 61 62 |L' (128,| purgeab|
|00004f30| 6c 65 29 20 7b 0d 09 7b | 0d 09 09 2f 2a 20 5b 31 |le) {..{|.../* [1|
|00004f40| 5d 20 2a 2f 0d 09 09 7b | 31 33 38 2c 20 32 35 36 |] */...{|138, 256|
|00004f50| 2c 20 31 35 36 2c 20 33 | 33 36 7d 2c 0d 09 09 42 |, 156, 3|36},...B|
|00004f60| 75 74 74 6f 6e 20 7b 20 | 65 6e 61 62 6c 65 64 2c |utton { |enabled,|
|00004f70| 20 22 4f 70 65 6e 22 20 | 7d 3b 0d 09 09 2f 2a 20 | "Open" |};.../* |
|00004f80| 5b 32 5d 20 2a 2f 0d 09 | 09 7b 31 31 35 32 2c 20 |[2] */..|.{1152, |
|00004f90| 35 39 2c 20 31 32 33 32 | 2c 20 37 37 7d 2c 0d 09 |59, 1232|, 77},..|
|00004fa0| 09 42 75 74 74 6f 6e 20 | 7b 20 65 6e 61 62 6c 65 |.Button |{ enable|
|00004fb0| 64 2c 20 22 48 69 64 64 | 65 6e 22 20 7d 3b 0d 09 |d, "Hidd|en" };..|
|00004fc0| 09 2f 2a 20 5b 33 5d 20 | 2a 2f 0d 09 09 7b 31 36 |./* [3] |*/...{16|
|00004fd0| 33 2c 20 32 35 36 2c 20 | 31 38 31 2c 20 33 33 36 |3, 256, |181, 336|
|00004fe0| 7d 2c 0d 09 09 42 75 74 | 74 6f 6e 20 7b 20 65 6e |},...But|ton { en|
|00004ff0| 61 62 6c 65 64 2c 20 22 | 43 61 6e 63 65 6c 22 20 |abled, "|Cancel" |
|00005000| 7d 3b 0d 09 09 2f 2a 20 | 5b 34 5d 20 2a 2f 0d 09 |};.../* |[4] */..|
|00005010| 09 7b 33 39 2c 20 32 35 | 32 2c 20 35 39 2c 20 33 |.{39, 25|2, 59, 3|
|00005020| 34 37 7d 2c 0d 09 09 55 | 73 65 72 49 74 65 6d 20 |47},...U|serItem |
|00005030| 7b 20 64 69 73 61 62 6c | 65 64 20 7d 3b 0d 09 09 |{ disabl|ed };...|
|00005040| 2f 2a 20 5b 35 5d 20 2a | 2f 0d 09 09 7b 36 38 2c |/* [5] *|/...{68,|
|00005050| 20 32 35 36 2c 20 38 36 | 2c 20 33 33 36 7d 2c 0d | 256, 86|, 336},.|
|00005060| 09 09 42 75 74 74 6f 6e | 20 7b 20 65 6e 61 62 6c |..Button| { enabl|
|00005070| 65 64 2c 20 22 45 6a 65 | 63 74 22 20 7d 3b 0d 09 |ed, "Eje|ct" };..|
|00005080| 09 2f 2a 20 5b 36 5d 20 | 2a 2f 0d 09 09 7b 39 33 |./* [6] |*/...{93|
|00005090| 2c 20 32 35 36 2c 20 31 | 31 31 2c 20 33 33 36 7d |, 256, 1|11, 336}|
|000050a0| 2c 0d 09 09 42 75 74 74 | 6f 6e 20 7b 20 65 6e 61 |,...Butt|on { ena|
|000050b0| 62 6c 65 64 2c 20 22 44 | 72 69 76 65 22 20 7d 3b |bled, "D|rive" };|
|000050c0| 0d 09 09 2f 2a 20 5b 37 | 5d 20 2a 2f 0d 09 09 7b |.../* [7|] */...{|
|000050d0| 33 39 2c 20 31 32 2c 20 | 31 38 35 2c 20 32 33 30 |39, 12, |185, 230|
|000050e0| 7d 2c 0d 09 09 55 73 65 | 72 49 74 65 6d 20 7b 20 |},...Use|rItem { |
|000050f0| 65 6e 61 62 6c 65 64 20 | 7d 3b 0d 09 09 2f 2a 20 |enabled |};.../* |
|00005100| 5b 38 5d 20 2a 2f 0d 09 | 09 7b 33 39 2c 20 32 32 |[8] */..|.{39, 22|
|00005110| 39 2c 20 31 38 35 2c 20 | 32 34 35 7d 2c 0d 09 09 |9, 185, |245},...|
|00005120| 55 73 65 72 49 74 65 6d | 20 7b 20 65 6e 61 62 6c |UserItem| { enabl|
|00005130| 65 64 20 7d 3b 0d 09 09 | 2f 2a 20 5b 39 5d 20 2a |ed };...|/* [9] *|
|00005140| 2f 0d 09 09 7b 31 32 34 | 2c 20 32 35 32 2c 20 31 |/...{124|, 252, 1|
|00005150| 32 35 2c 20 33 34 30 7d | 2c 0d 09 09 55 73 65 72 |25, 340}|,...User|
|00005160| 49 74 65 6d 20 7b 20 64 | 69 73 61 62 6c 65 64 20 |Item { d|isabled |
|00005170| 7d 3b 0d 09 09 2f 2a 20 | 5b 31 30 5d 20 2a 2f 0d |};.../* |[10] */.|
|00005180| 09 09 7b 31 30 34 34 2c | 20 32 30 2c 20 31 31 34 |..{1044,| 20, 114|
|00005190| 35 2c 20 31 31 36 7d 2c | 0d 09 09 53 74 61 74 69 |5, 116},|...Stati|
|000051a0| 63 54 65 78 74 20 7b 20 | 64 69 73 61 62 6c 65 64 |cText { |disabled|
|000051b0| 2c 20 22 22 20 7d 3b 0d | 09 09 2f 2a 20 5b 31 31 |, "" };.|../* [11|
|000051c0| 5d 20 2a 2f 0d 09 09 7b | 31 2c 20 31 34 2c 20 32 |] */...{|1, 14, 2|
|000051d0| 30 2c 20 31 34 32 7d 2c | 0d 09 09 52 61 64 69 6f |0, 142},|...Radio|
|000051e0| 42 75 74 74 6f 6e 20 7b | 20 65 6e 61 62 6c 65 64 |Button {| enabled|
|000051f0| 2c 20 22 54 65 78 74 20 | 66 69 6c 65 73 20 6f 6e |, "Text |files on|
|00005200| 6c 79 22 20 7d 3b 0d 09 | 09 2f 2a 20 5b 31 32 5d |ly" };..|./* [12]|
|00005210| 20 2a 2f 0d 09 09 7b 31 | 39 2c 20 31 34 2c 20 33 | */...{1|9, 14, 3|
|00005220| 38 2c 20 31 37 36 7d 2c | 0d 09 09 52 61 64 69 6f |8, 176},|...Radio|
|00005230| 42 75 74 74 6f 6e 20 7b | 20 65 6e 61 62 6c 65 64 |Button {| enabled|
|00005240| 2c 20 22 54 65 78 74 20 | 61 6e 64 20 61 70 70 6c |, "Text |and appl|
|00005250| 69 63 61 74 69 6f 6e 73 | 22 20 7d 3b 0d 09 09 2f |ications|" };.../|
|00005260| 2a 20 5b 31 33 5d 20 2a | 2f 0d 09 09 7b 36 2c 20 |* [13] *|/...{6, |
|00005270| 32 35 36 2c 20 32 34 2c | 20 33 33 36 7d 2c 0d 09 |256, 24,| 336},..|
|00005280| 09 42 75 74 74 6f 6e 20 | 7b 20 65 6e 61 62 6c 65 |.Button |{ enable|
|00005290| 64 2c 20 22 51 75 69 74 | 22 20 7d 0d 09 7d 0d 7d |d, "Quit|" }..}.}|
|000052a0| 3b 0d 46 75 72 74 68 65 | 72 20 52 65 66 65 72 65 |;.Furthe|r Refere|
|000052b0| 6e 63 65 3a 0d a5 09 54 | 68 65 20 53 74 61 6e 64 |nce:...T|he Stand|
|000052c0| 61 72 64 20 46 69 6c 65 | 20 50 61 63 6b 61 67 65 |ard File| Package|
|000052d0| 0d a5 09 49 6e 73 69 64 | 65 20 4d 61 63 69 6e 74 |...Insid|e Macint|
|000052e0| 6f 73 68 3a 20 46 69 6c | 65 73 2c 20 53 74 61 6e |osh: Fil|es, Stan|
|000052f0| 64 61 72 64 20 46 69 6c | 65 20 50 61 63 6b 61 67 |dard Fil|e Packag|
|00005300| 65 0d 12 6a 00 00 00 00 | 03 48 02 52 00 11 02 ff |e..j....|.H.R....|
|00005310| 0c 00 ff ff ff ff 00 00 | 00 00 00 00 00 00 02 52 |........|.......R|
|00005320| 00 00 03 48 00 00 00 00 | 00 00 00 a1 00 64 00 0c |...H....|.....d..|
|00005330| 57 4f 52 44 00 00 00 00 | 00 53 01 ca 00 a0 00 8c |WORD....|.S......|
|00005340| 00 a1 00 64 00 0c 57 4f | 52 44 00 00 00 00 00 52 |...d..WO|RD.....R|
|00005350| 01 c9 00 a0 00 82 00 1e | 00 01 00 0a 00 2f 00 5a |........|...../.Z|
|00005360| 00 81 02 23 00 07 00 00 | 00 00 00 08 00 0a 00 09 |...#....|........|
|00005370| 30 49 88 3a b5 9c f0 39 | 00 22 00 7b 02 1a 00 00 |0I.:...9|.".{....|
|00005380| 00 09 ff ff ff ff ff ff | ff ff 00 23 00 00 00 a0 |........|...#....|
|00005390| 00 c4 00 a1 00 64 00 0a | 4f 4e 4c 4e 00 66 00 00 |.....d..|ONLN.f..|
|000053a0| 01 fe 00 a0 00 8c 00 a1 | 00 64 00 31 64 72 77 32 |........|.d.1drw2|
|000053b0| 00 02 01 c9 00 2d 01 e1 | 01 5f 00 00 80 00 00 00 |.....-..|._......|
|000053c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 ff ff |........|........|
|000053d0| ff ff ff ff 00 01 00 00 | 01 8f 00 00 00 00 00 a1 |........|........|
|000053e0| 00 96 00 0c 01 00 00 00 | 02 78 00 00 00 00 00 00 |........|.x......|
|000053f0| 00 a1 00 64 00 10 64 72 | 77 32 00 3a 00 05 00 00 |...d..dr|w2.:....|
|00005400| 00 00 00 01 00 00 00 a1 | 00 64 00 0e 64 72 77 32 |........|.d..drw2|
|00005410| 00 3a 00 02 00 24 00 00 | 00 00 00 a1 00 64 00 34 |.:...$..|.....d.4|
|00005420| 64 72 77 32 00 3a 00 01 | 00 03 01 00 00 18 00 00 |drw2.:..|........|
|00005430| 00 00 00 00 00 00 00 00 | 00 01 00 01 00 01 00 01 |........|........|
|00005440| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005450| 00 00 00 00 00 a1 00 9a | 00 08 ff fa 00 00 00 97 |........|........|
|00005460| 40 00 00 a0 00 98 00 2c | 00 08 00 14 05 54 69 6d |@......,|.....Tim|
|00005470| 65 73 00 03 00 14 00 04 | 01 00 00 0d 00 18 00 2e |es......|........|
|00005480| 00 04 00 00 01 00 00 10 | 65 52 53 0f 65 52 53 0f |........|eRS.eRS.|
|00005490| 00 2b 5d 42 13 4e 65 77 | 20 54 65 63 68 6e 69 63 |.+]B.New| Technic|
|000054a0| 61 6c 20 4e 6f 74 65 73 | 00 a0 00 99 00 a1 00 64 |al Notes|.......d|
|000054b0| 00 08 64 72 77 32 00 3a | 00 04 00 a1 14 e3 00 02 |..drw2.:|........|
|000054c0| 00 01 00 a0 00 97 00 a1 | 00 64 00 31 64 72 77 32 |........|.d.1drw2|
|000054d0| 00 02 02 06 01 65 02 19 | 01 f4 00 00 80 00 00 00 |.....e..|........|
|000054e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 ff ff |........|........|
|000054f0| ff ff ff ff 00 01 00 00 | 01 50 00 00 00 00 00 a1 |........|.P......|
|00005500| 00 96 00 0c 01 00 00 00 | 02 78 00 00 00 00 00 00 |........|.x......|
|00005510| 00 a1 00 64 00 10 64 72 | 77 32 00 3a 00 05 00 00 |...d..dr|w2.:....|
|00005520| 00 00 00 01 00 00 00 a1 | 00 64 00 0e 64 72 77 32 |........|.d..drw2|
|00005530| 00 3a 00 02 00 24 00 00 | 00 00 00 a1 00 64 00 34 |.:...$..|.....d.4|
|00005540| 64 72 77 32 00 3a 00 01 | 00 03 00 00 00 12 00 00 |drw2.:..|........|
|00005550| 00 00 00 00 00 00 00 00 | 00 01 00 01 00 01 00 01 |........|........|
|00005560| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005570| 00 00 00 00 00 a1 00 9a | 00 08 ff fb 80 00 00 45 |........|.......E|
|00005580| c0 00 00 a0 00 98 00 04 | 00 00 00 0d 00 12 00 15 |........|........|
|00005590| 16 80 00 28 00 7b 01 95 | 11 44 65 76 65 6c 6f 70 |...(.{..|.Develop|
|000055a0| 65 72 20 53 75 70 70 6f | 72 74 00 a0 00 99 00 a1 |er Suppo|rt......|
|000055b0| 00 64 00 08 64 72 77 32 | 00 3a 00 04 00 a1 14 e3 |.d..drw2|.:......|
|000055c0| 00 02 00 01 00 a0 00 97 | 00 a1 00 64 00 60 64 72 |........|...d.`dr|
|000055d0| 77 32 00 03 02 00 00 2d | 02 00 01 ef 00 00 00 00 |w2.....-|........|
|000055e0| 00 00 00 00 02 02 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000055f0| ff ff ff ff ff ff 00 01 | 00 01 08 4b 00 00 00 00 |........|...K....|
|00005600| 02 00 01 ef 02 00 00 2d | 00 00 00 00 00 00 00 00 |.......-|........|
|00005610| 00 01 00 14 00 0c 00 03 | 00 02 00 00 00 5a 00 01 |........|.....Z..|
|00005620| 00 00 00 02 00 00 00 03 | 00 0c 00 00 00 00 00 07 |........|........|
|00005630| 00 02 00 02 00 08 00 08 | 00 20 00 66 02 1c 00 66 |........|. .f...f|
|00005640| 00 5a 00 a1 00 64 00 31 | 64 72 77 32 00 02 01 ca |.Z...d.1|drw2....|
|00005650| 01 c0 01 fa 01 e9 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005660| 00 00 00 00 00 00 00 00 | 00 00 ff ff ff ff ff ff |........|........|
|00005670| 00 01 00 00 01 4b 00 00 | 00 00 00 a1 00 96 00 0c |.....K..|........|
|00005680| 01 00 00 00 02 78 00 00 | 00 00 00 00 00 a1 00 64 |.....x..|.......d|
|00005690| 00 10 64 72 77 32 00 3a | 00 05 00 00 00 00 00 01 |..drw2.:|........|
|000056a0| 00 00 00 a1 00 64 00 0e | 64 72 77 32 00 3a 00 02 |.....d..|drw2.:..|
|000056b0| 00 24 00 00 00 00 00 a1 | 00 64 00 34 64 72 77 32 |.$......|.d.4drw2|
|000056c0| 00 3a 00 01 00 03 00 00 | 00 30 00 00 00 00 00 00 |.:......|.0......|
|000056d0| 00 00 00 00 00 01 00 01 | 00 01 00 01 00 00 00 00 |........|........|
|000056e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000056f0| 00 a1 00 9a 00 08 ff f4 | 00 00 00 13 80 00 00 a0 |........|........|
|00005700| 00 98 00 0d 00 30 00 28 | 00 55 01 ef 01 f0 00 a0 |.....0.(|.U......|
|00005710| 00 99 00 a1 00 64 00 08 | 64 72 77 32 00 3a 00 04 |.....d..|drw2.:..|
|00005720| 00 a1 14 e3 00 02 00 01 | 00 a0 00 97 00 a1 00 64 |........|.......d|
|00005730| 00 31 64 72 77 32 00 02 | 01 ef 01 e6 01 fa 01 f0 |.1drw2..|........|
|00005740| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005750| 00 00 00 00 ff ff ff ff | ff ff 00 01 00 00 01 00 |........|........|
|00005760| 00 00 00 00 00 a1 00 96 | 00 0c 01 00 00 00 02 78 |........|.......x|
|00005770| 00 00 00 00 00 00 00 a1 | 00 64 00 10 64 72 77 32 |........|.d..drw2|
|00005780| 00 3a 00 05 00 00 00 00 | 00 01 00 00 00 a1 00 64 |.:......|.......d|
|00005790| 00 0e 64 72 77 32 00 3a | 00 02 00 24 00 00 00 00 |..drw2.:|...$....|
|000057a0| 00 a1 00 64 00 34 64 72 | 77 32 00 3a 00 01 00 03 |...d.4dr|w2.:....|
|000057b0| 00 00 00 09 00 00 00 00 | 00 00 00 00 00 00 00 01 |........|........|
|000057c0| 00 01 00 01 00 01 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000057d0| 00 00 00 00 00 00 00 00 | 00 00 00 a1 00 9a 00 08 |........|........|
|000057e0| ff fd 80 00 00 04 00 00 | 00 a0 00 98 00 0d 00 09 |........|........|
|000057f0| 00 15 6c 00 00 2b 26 09 | 01 a8 00 a0 00 99 00 a1 |..l..+&.|........|
|00005800| 00 64 00 08 64 72 77 32 | 00 3a 00 04 00 a1 14 e3 |.d..drw2|.:......|
|00005810| 00 02 00 01 00 a0 00 97 | 00 a1 00 64 00 31 64 72 |........|...d.1dr|
|00005820| 77 32 00 02 01 e5 00 2d | 01 f8 00 79 00 00 00 00 |w2.....-|...y....|
|00005830| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005840| ff ff ff ff ff ff 00 01 | 00 01 01 00 00 00 01 00 |........|........|
|00005850| 00 a1 00 96 00 0c 01 00 | 00 00 02 78 00 00 00 00 |........|...x....|
|00005860| 00 00 00 a1 00 64 00 10 | 64 72 77 32 00 3a 00 05 |.....d..|drw2.:..|
|00005870| 00 00 00 00 00 01 00 00 | 00 a1 00 64 00 0e 64 72 |........|...d..dr|
|00005880| 77 32 00 3a 00 02 00 24 | 00 00 00 00 00 a1 00 64 |w2.:...$|.......d|
|00005890| 00 34 64 72 77 32 00 3a | 00 01 00 03 00 00 00 12 |.4drw2.:|........|
|000058a0| 00 00 00 00 00 00 00 00 | 00 00 00 01 00 01 00 01 |........|........|
|000058b0| 00 01 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000058c0| 00 00 00 00 00 00 00 a1 | 00 9a 00 08 ff fb 80 00 |........|........|
|000058d0| 00 25 00 00 00 a0 00 98 | 00 0d 00 12 00 15 42 80 |.%......|......B.|
|000058e0| 00 28 00 5a 00 5c 09 4d | 61 63 69 6e 74 6f 73 68 |.(.Z.\.M|acintosh|
|000058f0| 00 a0 00 99 00 a1 00 64 | 00 08 64 72 77 32 00 3a |.......d|..drw2.:|
|00005900| 00 04 00 a1 14 e3 00 02 | 00 01 00 a0 00 97 00 a0 |........|........|
|00005910| 00 8d 00 a1 00 64 00 06 | 64 72 77 32 00 44 00 a0 |.....d..|drw2.D..|
|00005920| 00 83 00 a1 00 64 00 04 | 57 4f 52 44 00 a0 00 8d |.....d..|WORD....|
|00005930| 00 01 00 0a 00 00 00 00 | 03 48 02 52 00 04 01 00 |........|.H.R....|
|00005940| 00 2e 00 04 00 00 00 00 | 00 10 00 01 00 01 00 01 |........|........|
|00005950| 00 01 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 00 00 |.....d..|ONLN.d..|
|00005960| 00 8e 00 5a 00 a1 01 88 | 00 28 00 9c 00 5a 23 46 |...Z....|.(...Z#F|
|00005970| 4c 20 33 33 20 2d 20 53 | 74 61 6e 64 61 72 64 20 |L 33 - S|tandard |
|00005980| 46 69 6c 65 20 43 75 73 | 74 6f 6d 69 7a 61 74 69 |File Cus|tomizati|
|00005990| 6f 6e 00 0d 00 0e 00 a1 | 00 64 00 10 4f 4e 4c 4e |on......|.d..ONLN|
|000059a0| 00 64 00 24 00 a0 00 5a | 00 af 00 7a 00 2a 10 05 |.d.$...Z|...z.*..|
|000059b0| 46 69 6c 65 73 00 00 04 | 00 00 00 0d 00 0c 00 a1 |Files...|........|
|000059c0| 00 64 00 10 4f 4e 4c 4e | 00 64 00 2c 00 bb 00 5a |.d..ONLN|.d.,...Z|
|000059d0| 00 c7 00 92 00 2a 18 0b | 52 65 76 69 73 65 64 20 |.....*..|Revised |
|000059e0| 62 79 3a 00 00 a1 00 64 | 00 10 4f 4e 4c 4e 00 64 |by:....d|..ONLN.d|
|000059f0| 00 39 00 bb 01 e3 00 c7 | 02 1c 00 28 00 c4 01 e3 |.9......|...(....|
|00005a00| 0a 4d 61 72 63 68 20 31 | 39 38 38 00 00 a1 00 64 |.March 1|988....d|
|00005a10| 00 10 4f 4e 4c 4e 00 64 | 00 44 00 c7 00 5a 00 d3 |..ONLN.d|.D...Z..|
|00005a20| 00 8f 00 28 00 d0 00 5a | 0b 57 72 69 74 74 65 6e |...(...Z|.Written|
|00005a30| 20 62 79 3a 00 a1 00 64 | 00 10 4f 4e 4c 4e 00 64 | by:...d|..ONLN.d|
|00005a40| 00 50 00 c7 00 a2 00 d3 | 00 ec 00 29 48 0f 4a 69 |.P......|...)H.Ji|
|00005a50| 6d 20 46 72 69 65 64 6c | 61 6e 64 65 72 00 00 a1 |m Friedl|ander...|
|00005a60| 00 64 00 10 4f 4e 4c 4e | 00 64 00 60 00 c7 01 dc |.d..ONLN|.d.`....|
|00005a70| 00 d3 02 1c 00 28 00 d0 | 01 dc 0c 4f 63 74 6f 62 |.....(..|...Octob|
|00005a80| 65 72 20 31 39 38 35 00 | 00 06 00 04 00 00 00 a1 |er 1985.|........|
|00005a90| 00 64 00 10 4f 4e 4c 4e | 00 64 00 6d 00 e0 00 5a |.d..ONLN|.d.m...Z|
|00005aa0| 00 ec 00 ff 00 28 00 e9 | 00 5a 1e 54 68 69 73 20 |.....(..|.Z.This |
|00005ab0| 6e 6f 74 65 20 63 6f 6e | 74 61 69 6e 73 20 61 6e |note con|tains an|
|00005ac0| 20 65 78 61 6d 70 6c 65 | 20 00 00 06 00 05 00 00 | example| .......|
|00005ad0| 00 a1 00 64 00 10 4f 4e | 4c 4e 00 64 00 8b 00 e0 |...d..ON|LN.d....|
|00005ae0| 00 ff 00 ec 01 ab 00 29 | a5 1e 70 72 6f 67 72 61 |.......)|..progra|
|00005af0| 6d 20 74 68 61 74 20 64 | 65 6d 6f 6e 73 74 72 61 |m that d|emonstra|
|00005b00| 74 65 73 20 68 6f 77 20 | 00 2c 00 0a 00 16 07 43 |tes how |.,.....C|
|00005b10| 6f 75 72 69 65 72 00 03 | 00 16 00 a1 00 64 00 10 |ourier..|.....d..|
|00005b20| 4f 4e 4c 4e 00 64 00 a9 | 00 df 01 ab 00 eb 01 f1 |ONLN.d..|........|
|00005b30| 00 29 ac 0a 53 46 50 47 | 65 74 46 69 6c 65 00 03 |.)..SFPG|etFile..|
|00005b40| 00 14 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 00 b3 |.....d..|ONLN.d..|
|00005b50| 00 e0 01 f1 00 ec 02 1c | 00 29 46 07 20 63 61 6e |........|.)F. can|
|00005b60| 20 62 65 00 00 06 00 00 | 00 00 00 a1 00 64 00 10 | be.....|.....d..|
|00005b70| 4f 4e 4c 4e 00 64 00 bb | 00 ec 00 5a 00 f8 01 6a |ONLN.d..|...Z...j|
|00005b80| 00 28 00 f5 00 5a 3b 63 | 75 73 74 6f 6d 69 7a 65 |.(...Z;c|ustomize|
|00005b90| 64 20 75 73 69 6e 67 20 | 74 68 65 20 64 69 61 6c |d using |the dial|
|00005ba0| 6f 67 20 68 6f 6f 6b 20 | 61 6e 64 20 66 69 6c 65 |og hook |and file|
|00005bb0| 20 66 69 6c 74 65 72 20 | 66 75 6e 63 74 69 6f 6e | filter |function|
|00005bc0| 73 2e 00 07 00 01 00 01 | 00 20 01 04 00 58 01 04 |s.......|. ...X..|
|00005bd0| 02 1d 00 03 00 16 00 06 | 00 04 00 00 00 a1 00 64 |........|.......d|
|00005be0| 00 10 4f 4e 4c 4e 00 64 | 00 f7 01 11 00 5a 01 1d |..ONLN.d|.....Z..|
|00005bf0| 00 a0 00 2a 26 0a 53 46 | 50 47 65 74 46 69 6c 65 |...*&.SF|PGetFile|
|00005c00| 00 03 00 14 00 a1 00 64 | 00 10 4f 4e 4c 4e 00 64 |.......d|..ONLN.d|
|00005c10| 01 01 01 12 00 a0 01 1e | 01 4f 00 29 46 21 d5 73 |........|.O.)F!.s|
|00005c20| 20 64 69 61 6c 6f 67 20 | 68 6f 6f 6b 20 66 75 6e | dialog |hook fun|
|00005c30| 63 74 69 6f 6e 20 61 6e | 64 20 66 69 6c 65 20 00 |ction an|d file .|
|00005c40| 00 06 00 05 00 00 00 a1 | 00 64 00 10 4f 4e 4c 4e |........|.d..ONLN|
|00005c50| 00 64 01 22 01 12 01 4f | 01 1e 02 1c 00 29 af 27 |.d."...O|.....).'|
|00005c60| 66 69 6c 74 65 72 20 66 | 75 6e 63 74 69 6f 6e 20 |filter f|unction |
|00005c70| 65 6e 61 62 6c 65 20 79 | 6f 75 20 74 6f 20 63 75 |enable y|ou to cu|
|00005c80| 73 74 6f 6d 69 7a 65 00 | 00 03 00 16 00 06 00 02 |stomize.|........|
|00005c90| 00 00 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 01 4a |.....d..|ONLN.d.J|
|00005ca0| 01 1e 00 5a 01 2a 00 a0 | 00 28 01 28 00 5a 0a 53 |...Z.*..|.(.(.Z.S|
|00005cb0| 46 50 47 65 74 46 69 6c | 65 00 00 03 00 14 00 a1 |FPGetFil|e.......|
|00005cc0| 00 64 00 10 4f 4e 4c 4e | 00 64 01 54 01 1f 00 a0 |.d..ONLN|.d.T....|
|00005cd0| 01 2b 01 92 00 29 46 32 | d5 73 20 62 65 68 61 76 |.+...)F2|.s behav|
|00005ce0| 69 6f 72 20 74 6f 20 66 | 69 74 20 74 68 65 20 6e |ior to f|it the n|
|00005cf0| 65 65 64 73 20 6f 66 20 | 79 6f 75 72 20 61 70 70 |eeds of |your app|
|00005d00| 6c 69 63 61 74 69 6f 6e | 2e 20 00 06 00 03 00 00 |lication|. ......|
|00005d10| 00 a1 00 64 00 10 4f 4e | 4c 4e 00 64 01 86 01 1f |...d..ON|LN.d....|
|00005d20| 01 92 01 2b 02 1c 00 29 | f2 1c 54 68 69 73 20 74 |...+...)|..This t|
|00005d30| 65 63 68 6e 69 63 61 6c | 20 6e 6f 74 65 20 63 6f |echnical| note co|
|00005d40| 6e 73 69 73 74 73 00 06 | 00 00 00 00 00 a1 00 64 |nsists..|.......d|
|00005d50| 00 10 4f 4e 4c 4e 00 64 | 01 a3 01 2b 00 5a 01 37 |..ONLN.d|...+.Z.7|
|00005d60| 01 1e 00 28 01 34 00 5a | 29 70 72 69 6d 61 72 69 |...(.4.Z|)primari|
|00005d70| 6c 79 20 6f 66 20 61 20 | 73 68 6f 72 74 20 65 78 |ly of a |short ex|
|00005d80| 61 6d 70 6c 65 20 70 72 | 6f 67 72 61 6d 20 74 68 |ample pr|ogram th|
|00005d90| 61 74 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 01 d1 |at...d..|ONLN.d..|
|00005da0| 01 44 00 5a 01 50 01 20 | 00 2a 19 2c 31 29 20 63 |.D.Z.P. |.*.,1) c|
|00005db0| 68 61 6e 67 65 73 20 74 | 68 65 20 74 69 74 6c 65 |hanges t|he title|
|00005dc0| 20 6f 66 20 74 68 65 20 | 4f 70 65 6e 20 62 75 74 | of the |Open but|
|00005dd0| 74 6f 6e 20 74 6f 20 d4 | 00 03 00 16 00 a1 00 64 |ton to .|.......d|
|00005de0| 00 10 4f 4e 4c 4e 00 64 | 01 fd 01 43 01 20 01 4f |..ONLN.d|...C. .O|
|00005df0| 01 4a 00 29 c6 06 4d 79 | 4f 70 65 6e 00 03 00 14 |.J.)..My|Open....|
|00005e00| 00 a1 00 64 00 10 4f 4e | 4c 4e 00 64 02 03 01 44 |...d..ON|LN.d...D|
|00005e10| 01 4a 01 50 01 52 00 29 | 2a 02 d5 2c 00 a1 00 64 |.J.P.R.)|*..,...d|
|00005e20| 00 10 4f 4e 4c 4e 00 64 | 02 06 01 50 00 5a 01 5c |..ONLN.d|...P.Z.\|
|00005e30| 01 d0 00 28 01 59 00 5a | 53 32 29 20 61 64 64 73 |...(.Y.Z|S2) adds|
|00005e40| 20 74 77 6f 20 72 61 64 | 69 6f 20 62 75 74 74 6f | two rad|io butto|
|00005e50| 6e 73 20 73 6f 20 74 68 | 61 74 20 74 68 65 20 75 |ns so th|at the u|
|00005e60| 73 65 72 20 63 61 6e 20 | 63 68 6f 6f 73 65 20 74 |ser can |choose t|
|00005e70| 6f 20 64 69 73 70 6c 61 | 79 20 65 69 74 68 65 72 |o displa|y either|
|00005e80| 20 74 65 78 74 20 66 69 | 6c 65 73 20 00 06 00 01 | text fi|les ....|
|00005e90| 00 00 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 02 59 |.....d..|ONLN.d.Y|
|00005ea0| 01 50 01 d0 01 5c 02 1c | 00 28 01 59 01 d0 11 6f |.P...\..|.(.Y...o|
|00005eb0| 72 20 74 65 78 74 20 66 | 69 6c 65 73 20 61 6e 64 |r text f|iles and|
|00005ec0| 00 06 00 00 00 00 00 a1 | 00 64 00 10 4f 4e 4c 4e |........|.d..ONLN|
|00005ed0| 00 64 02 6b 01 5c 00 5a | 01 68 00 96 00 28 01 65 |.d.k.\.Z|.h...(.e|
|00005ee0| 00 5a 0d 61 70 70 6c 69 | 63 61 74 69 6f 6e 73 2e |.Z.appli|cations.|
|00005ef0| 00 a1 00 64 00 10 4f 4e | 4c 4e 00 64 02 79 01 69 |...d..ON|LN.d.y.i|
|00005f00| 00 5a 01 75 00 db 00 2a | 0d 1d 33 29 20 61 64 64 |.Z.u...*|..3) add|
|00005f10| 73 20 61 20 71 75 69 74 | 20 62 75 74 74 6f 6e 20 |s a quit| button |
|00005f20| 74 6f 20 74 68 65 20 00 | 00 03 00 16 00 a1 00 64 |to the .|.......d|
|00005f30| 00 10 4f 4e 4c 4e 00 64 | 02 96 01 68 00 db 01 74 |..ONLN.d|...h...t|
|00005f40| 01 21 00 29 81 0a 53 46 | 50 47 65 74 46 69 6c 65 |.!.)..SF|PGetFile|
|00005f50| 00 03 00 14 00 a1 00 64 | 00 10 4f 4e 4c 4e 00 64 |.......d|..ONLN.d|
|00005f60| 02 a0 01 69 01 21 01 75 | 01 45 00 29 46 08 20 64 |...i.!.u|.E.)F. d|
|00005f70| 69 61 6c 6f 67 2c 00 a1 | 00 64 00 10 4f 4e 4c 4e |ialog,..|.d..ONLN|
|00005f80| 00 64 02 ab 01 81 00 5a | 01 8d 01 86 00 28 01 8a |.d.....Z|.....(..|
|00005f90| 00 5a 42 41 6c 6c 20 74 | 68 69 73 20 69 73 20 64 |.ZBAll t|his is d|
|00005fa0| 6f 6e 65 20 69 6e 20 61 | 20 77 61 79 20 73 6f 20 |one in a| way so |
|00005fb0| 61 73 20 74 6f 20 70 72 | 6f 76 69 64 65 20 63 6f |as to pr|ovide co|
|00005fc0| 6d 70 61 74 69 62 69 6c | 69 74 79 20 77 69 74 68 |mpatibil|ity with|
|00005fd0| 20 74 68 65 20 00 00 06 | 00 01 00 00 00 a1 00 64 | the ...|.......d|
|00005fe0| 00 10 4f 4e 4c 4e 00 64 | 02 ed 01 81 01 86 01 8d |..ONLN.d|........|
|00005ff0| 02 1c 00 28 01 8a 01 86 | 1c 4d 61 63 69 6e 74 6f |...(....|.Macinto|
|00006000| 73 68 20 46 69 6c 65 20 | 53 79 73 74 65 6d 20 28 |sh File |System (|
|00006010| 4d 46 53 29 2c 00 00 06 | 00 00 00 00 00 a1 00 64 |MFS),...|.......d|
|00006020| 00 10 4f 4e 4c 4e 00 64 | 03 0a 01 8d 00 5a 01 99 |..ONLN.d|.....Z..|
|00006030| 01 50 00 28 01 96 00 5a | 33 74 68 65 20 48 69 65 |.P.(...Z|3the Hie|
|00006040| 72 61 72 63 68 69 63 61 | 6c 20 46 69 6c 65 20 53 |rarchica|l File S|
|00006050| 79 73 74 65 6d 20 28 48 | 46 53 29 20 61 6e 64 20 |ystem (H|FS) and |
|00006060| 28 68 6f 70 65 66 75 6c | 6c 79 29 20 00 06 00 01 |(hopeful|ly) ....|
|00006070| 00 00 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 03 3d |.....d..|ONLN.d.=|
|00006080| 01 8d 01 50 01 99 02 1c | 00 29 f6 29 66 75 74 75 |...P....|.).)futu|
|00006090| 72 65 20 73 79 73 74 65 | 6d 73 2e 20 49 66 20 79 |re syste|ms. If y|
|000060a0| 6f 75 20 68 61 76 65 20 | 61 6e 79 20 71 75 65 73 |ou have |any ques|
|000060b0| 74 69 6f 6e 73 00 00 06 | 00 00 00 00 00 a1 00 64 |tions...|.......d|
|000060c0| 00 10 4f 4e 4c 4e 00 64 | 03 67 01 99 00 5a 01 a5 |..ONLN.d|.g...Z..|
|000060d0| 00 7c 00 28 01 a2 00 5a | 07 61 73 20 79 6f 75 20 |.|.(...Z|.as you |
|000060e0| 00 06 00 01 00 00 00 a1 | 00 64 00 10 4f 4e 4c 4e |........|.d..ONLN|
|000060f0| 00 64 03 6e 01 99 00 7c | 01 a5 02 1c 00 29 22 55 |.d.n...||.....)"U|
|00006100| 72 65 61 64 2c 20 74 68 | 65 20 63 6f 6d 70 6c 65 |read, th|e comple|
|00006110| 74 65 20 73 6f 75 72 63 | 65 20 6f 66 20 74 68 65 |te sourc|e of the|
|00006120| 20 64 65 6d 6f 20 70 72 | 6f 67 72 61 6d 20 61 6e | demo pr|ogram an|
|00006130| 64 20 74 68 65 20 72 65 | 73 6f 75 72 63 65 20 63 |d the re|source c|
|00006140| 6f 6d 70 69 6c 65 72 20 | 69 6e 70 75 74 20 66 69 |ompiler |input fi|
|00006150| 6c 65 20 69 73 00 00 06 | 00 00 00 00 00 a1 00 64 |le is...|.......d|
|00006160| 00 10 4f 4e 4c 4e 00 64 | 03 c4 01 a5 00 5a 01 b1 |..ONLN.d|.....Z..|
|00006170| 01 1c 00 28 01 ae 00 5a | 2b 70 72 6f 76 69 64 65 |...(...Z|+provide|
|00006180| 64 20 61 74 20 74 68 65 | 20 65 6e 64 20 6f 66 20 |d at the| end of |
|00006190| 74 68 69 73 20 74 65 63 | 68 6e 69 63 61 6c 20 6e |this tec|hnical n|
|000061a0| 6f 74 65 2e 00 a1 00 64 | 00 10 4f 4e 4c 4e 00 64 |ote....d|..ONLN.d|
|000061b0| 03 f0 01 bd 00 5a 01 c9 | 01 c0 00 2a 18 4e 42 61 |.....Z..|...*.NBa|
|000061c0| 73 69 63 61 6c 6c 79 2c | 20 77 65 20 6e 65 65 64 |sically,| we need|
|000061d0| 20 74 6f 20 64 6f 20 74 | 68 72 65 65 20 74 68 69 | to do t|hree thi|
|000061e0| 6e 67 73 3a 20 61 64 64 | 20 6f 75 72 20 65 78 74 |ngs: add| our ext|
|000061f0| 72 61 20 63 6f 6e 74 72 | 6f 6c 73 20 74 6f 20 74 |ra contr|ols to t|
|00006200| 68 65 20 72 65 73 6f 75 | 72 63 65 20 00 06 00 01 |he resou|rce ....|
|00006210| 00 00 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 04 3e |.....d..|ONLN.d.>|
|00006220| 01 bd 01 c0 01 c9 02 1c | 00 28 01 c6 01 c0 14 63 |........|.(.....c|
|00006230| 6f 6d 70 69 6c 65 72 20 | 69 6e 70 75 74 20 66 69 |ompiler |input fi|
|00006240| 6c 65 2c 00 00 06 00 00 | 00 00 00 a1 00 64 00 10 |le,.....|.....d..|
|00006250| 4f 4e 4c 4e 00 64 04 53 | 01 c9 00 5a 01 d5 01 73 |ONLN.d.S|...Z...s|
|00006260| 00 28 01 d2 00 5a 3f 77 | 72 69 74 65 20 61 20 64 |.(...Z?w|rite a d|
|00006270| 69 61 6c 6f 67 20 68 6f | 6f 6b 20 66 75 6e 63 74 |ialog ho|ok funct|
|00006280| 69 6f 6e 2c 20 61 6e 64 | 20 77 72 69 74 65 20 61 |ion, and| write a|
|00006290| 20 66 69 6c 65 20 66 69 | 6c 74 65 72 20 66 75 6e | file fi|lter fun|
|000062a0| 63 74 69 6f 6e 2e 00 04 | 01 00 00 0d 00 0e 00 a1 |ction...|........|
|000062b0| 00 64 00 10 4f 4e 4c 4e | 00 64 04 93 01 ed 00 5a |.d..ONLN|.d.....Z|
|000062c0| 01 fc 01 83 00 2a 27 2a | 4d 6f 64 69 66 79 69 6e |.....*'*|Modifyin|
|000062d0| 67 20 74 68 65 20 52 65 | 73 6f 75 72 63 65 20 43 |g the Re|source C|
|000062e0| 6f 6d 70 69 6c 65 72 20 | 49 6e 70 75 74 20 46 69 |ompiler |Input Fi|
|000062f0| 6c 65 00 04 00 00 00 0d | 00 0c 00 a1 00 64 00 10 |le......|.....d..|
|00006300| 4f 4e 4c 4e 00 64 04 be | 02 08 00 5a 02 14 01 bc |ONLN.d..|...Z....|
|00006310| 00 2a 18 4c 46 69 72 73 | 74 20 77 65 20 6e 65 65 |.*.LFirs|t we nee|
|00006320| 64 20 74 6f 20 64 65 66 | 69 6e 65 20 61 20 64 69 |d to def|ine a di|
|00006330| 61 6c 6f 67 20 69 6e 20 | 6f 75 72 20 72 65 73 6f |alog in |our reso|
|00006340| 75 72 63 65 20 66 69 6c | 65 2e 20 49 74 20 77 69 |urce fil|e. It wi|
|00006350| 6c 6c 20 62 65 20 44 4c | 4f 47 20 23 31 32 38 3a |ll be DL|OG #128:|
|00006360| 00 03 00 16 00 0d 00 09 | 00 a1 00 64 00 10 4f 4e |........|...d..ON|
|00006370| 4c 4e 00 64 05 0c 02 20 | 00 7e 02 2b 00 e7 00 2b |LN.d... |.~.+...+|
|00006380| 24 17 15 43 4f 4e 53 54 | 20 6d 79 44 4c 4f 47 49 |$..CONST| myDLOGI|
|00006390| 44 20 3d 20 31 32 38 3b | 00 03 00 14 00 0d 00 0c |D = 128;|........|
|000063a0| 00 a1 00 64 00 10 4f 4e | 4c 4e 00 64 05 22 02 36 |...d..ON|LN.d.".6|
|000063b0| 00 5a 02 42 00 d7 00 28 | 02 3f 00 5a 1c 61 6e 64 |.Z.B...(|.?.Z.and|
|000063c0| 20 69 74 d5 73 20 52 65 | 7a 20 64 65 73 63 72 69 | it.s Re|z descri|
|000063d0| 70 74 69 6f 6e 20 69 73 | 3a 00 00 03 00 16 00 0d |ption is|:.......|
|000063e0| 00 09 00 a1 00 64 00 10 | 4f 4e 4c 4e 00 64 05 40 |.....d..|ONLN.d.@|
|000063f0| 02 4e 00 7e 02 59 01 28 | 00 2b 24 17 22 72 65 73 |.N.~.Y.(|.+$."res|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.